Subject: Re: position() question From: David Carlisle <davidc@xxxxxxxxx> Date: Wed, 17 Nov 1999 12:12:25 GMT |
> Why do I get in version a even numbers 2, 4, 6, ... ? Modify your template like so: <xsl:template match="item"> <xsl:variable name="x" select="position()"/> <xsl:value-of select=" concat('(',preceding-sibling::node()[position() = $x -1],')')"/> <xsl:call-template name="output-position"/> </xsl:template> and you will see what is contained in the nodes at odd positions. The current node list in the xsl:for-all case is different and only contains the item nodes (as that is what you selected) so in that case the items are in positions 1, 2, 3. David XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
position() question, Oliver Becker | Thread | RE: position() question, Kay Michael |
position() question, Oliver Becker | Date | RE: xt:mkdir, Smith, Brian BC SSI |
Month |