Subject: Re: [xsl] Set <xsl:sort> attributes with stylesheet parameters From: Jeni Tennison <jeni@xxxxxxxxxxxxxxxx> Date: Thu, 30 Oct 2003 10:29:04 +0000 |
Hi Richard, > Why does the following code: > > <xsl:sort select="*[local-name()=$sort-by]" order="$sort-order" /> > > not sort in the order specified by the value $sort-order? Because you've forgotten to use an attribute value template ({}s) to indicate that the sort order is the value of the $sort-order variable, rather than the literal string "$sort-order". Try: <xsl:sort select="*[local-name() = $sort-by]" order="{$sort-order}" /> Cheers, Jeni --- Jeni Tennison http://www.jenitennison.com/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] Set <xsl:sort> attributes wit, Richard Lewis | Thread | RE: [xsl] Set <xsl:sort> attributes, Michael Kay |
Re: [xsl] XSL Grouping Trouble, David Carlisle | Date | Re: [xsl] displaying selective link, james walker |
Month |