findvalue('//a[1]');
I use HTML::TreeBuilder::XPathin perl. Now...">
All geek questions in one place
Why does the following XPath statement return all "a" elements?
print $tree->findvalue('//a[1]');
I use HTML::TreeBuilder::XPathin perl. Now I expect the above statute to return the value of the second element “a”, but instead will return the value of all “a” elements on the page. I can’t understand why?