Re: [xsl] xsl:sort now working under unix

Subject: Re: [xsl] xsl:sort now working under unix
From: Anton Triest <anton@xxxxxxxx>
Date: Thu, 23 Dec 2004 00:59:41 +0100
Hi Sylvia,

<xsl:for-each select="/runs/case">
<!--ascending or descending-->
<xsl:apply-templates select="document(@filename)/case">
<xsl:sort select="/case/status" data-type = "text" order="descending"/>

xsl:apply-templates sets the context node to a case element, and status is a child element of case,
so you'll need <xsl:sort select="status" .../>

I don't think a sort select expression should ever start with "/": it is a valid XPath expression but it's "fixed"
(ie. it doesn't change over the various elements you apply-templates to.)


Current Thread