[Home] [By Thread] [By Date] [Recent Entries]
David Carlisle schrieb:
Why is this so? Why does xsl:for-each obliterate the direction offered by the axis? That's an important distinction I wasn't making. (1) The axis imposes an order while the expression collects nodes, which
may be either document order or reverse document order.
(2) The result is a node set, unordered by definition.
(3) The xsl:for-each re-imposes an order, which by default happens to be
document order.Failing to make this distinction may result in confusion on behalf of the user, who may never have _seen_ the absence of order since a default order - document order - governs the functioning of xsl:for-each. If you use xslt 2 then the underlying datatype changes from sets to ordered sequences and then variables can hold sequences in specific order (and xsl:for-each will also iterate over the sequence in order)
Thanks a lot, David! Michael
|

Cart



