Lists Home |
Date Index |
>I want to make a XPath expression that finds the 5 first nodes that have a
>attribute "namn" thats equals "Tomas". Is it possible?
>I suppose it should be something like this:
Something like that!
You forgot the * after //, but you also have the problem that
position() will return the position of the node amongst its matching
siblings, not amongst all the matching nodes. You need to parenthesize
the first part of the expression to get the effect you want: