Subject: Re: [xsl] can't get xsl:sort to work From: "Joris Gillis" <roac@xxxxxxxxxx> Date: Mon, 19 Sep 2005 13:01:31 +0200 |
<xsl:for-each select="//complexarticle | //simplearticle | //dummyarticle"> <xsl:sort select="@entry"> <tr valign="top"> <td><xsl:value-of select="@id"/></td> <td><xsl:value-of select="@entry"/></td> <td><xsl:variable name="x" select="count(.//xref)"/> <xsl:for-each select=".//xref"> <xsl:value-of select="."/> <xsl:if test="position() < $x"> <br/> </xsl:if> </xsl:for-each> </td> </tr> </xsl:sort> </xsl:for-each>
but when i run the transformation (i'm using xmlspy) i get and error "Expected select attribute or non empty content not both" but i have a select attribute.
The error message says it all. You need: <xsl:sort select="@entry"/> you don't have to encapsulate the whole loop with this element;-)
regards, -- Joris Gillis (http://users.telenet.be/root-jg/me.html) Gaudiam omnibus traderat W3C, nec vana fides
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] can't get xsl:sort to work, UlyLee | Thread | Re: [xsl] can't get xsl:sort to wor, UlyLee |
[xsl] can't get xsl:sort to work, UlyLee | Date | Re: [xsl] can't get xsl:sort to wor, David Carlisle |
Month |