Jorge . chocolate(_dot_)camera(_at_)gmail(_dot_)com wrote:
And yet, indeed as per your answers, if I query the position of that
node, the value returned is 1 instead of 3:
<xsl:sequence select="$FOO[position() eq 3]/position()"/> → 1
which looks bizarre to me.
If you look at http://www.w3.org/TR/xpath20/#id-path-expressions then
you see that for
E1/E2
(where in your case E1 is $FOO[position() eq 3] and E2 the position()
function call) it says that first E1 is evaluated and then "Each node
resulting from the evaluation of E1 then serves in turn to provide an
inner focus for an evaluation of E2".
So doing
E1/position()
always (as long as E1 evaluates to a sequence of nodes) returns 1 as the
context size is 1.
--~----------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
EasyUnsubscribe: http://lists.mulberrytech.com/unsub/xsl-list/1167547
or by email: xsl-list-unsub(_at_)lists(_dot_)mulberrytech(_dot_)com
--~--