cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Leonid Kleiner" <mtfleo...@fibimail.co.il>
Subject Re: XSL-question: sort with parameter
Date Wed, 27 Mar 2002 08:41:24 GMT
Try this. Here datatypes also are of concern :).

<xsl:when test="$xsldttype='number'">
  <xsl:for-each select="DATALINE/*[name() = $xslcol]">
  <xsl:sort select="." data-type="number"/>
            <xsl:call-template name = "tablerow" />
 </xsl:for-each>
 </xsl:when>

<xsl:when test="$xsldttype='text'">
  <xsl:for-each select="DATALINE/*[name() = $xslcol]">
  <xsl:sort select="."/>
            <xsl:call-template name = "tablerow" />
 </xsl:for-each>
 </xsl:when>

Try to search for examples on www.google.com.

Have fun,
Leonid Kleiner


----- Original Message ----- 
From: "Axel Honfi" <e9626377@student.tuwien.ac.at>
To: <cocoon-users@xml.apache.org>
Sent: Wednesday, March 27, 2002 6:22 AM
Subject: XSL-question: sort with parameter


> Hi!
> 
> I passed a parameter to a stylesheet and I can get the value with
> <xsl:value-of select="$order-by"/>.
> 
> But I need to sort data by the value of the parameter like
> 
> <xsl:sort select="$order-by" order="ascending"/>.
> 
> But with this nothing happens and all other forms I tried also failed.
> 
> Does anyone know how to work this?
> 
> Thanks a lot
> 
> Axel
> 
> ---------------------------------------------------------------------
> Please check that your question has not already been answered in the
> FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
> 
> To unsubscribe, e-mail: <cocoon-users-unsubscribe@xml.apache.org>
> For additional commands, e-mail: <cocoon-users-help@xml.apache.org>


---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail: <cocoon-users-help@xml.apache.org>


Mime
View raw message