[xsl] Choosing different sorts

Subject: [xsl] Choosing different sorts
From: "Derek Hohls" <DHohls@xxxxxxxxxx>
Date: Thu, 15 Jul 2004 08:31:00 +0200
I had a look in the archives before posting, and am
not sure I understand the method which uses:

<xsl:sort select="*[name(.) = $sortfield]"/>

I have tried, in my code to have:

  <xsl:for-each select="file">
        <xsl:when test="$sort='design'"><xsl:sort
        <xsl:when test="$sort='stat'"><xsl:sort
        <xsl:otherwise><xsl:sort select="id"/></xsl:otherwise>         


where $sort is a parameter passed in (via another web page).
(NB: the actual select fields are quite long path strings...)

but this is clearly wrong!

Any guidance on this area would be welcome.


This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
MailScanner thanks transtec Computers for their support.

Current Thread