Subject:sort by variable Author:Ivan Pedruzzi Date:10 Oct 2006 12:13 PM
Giancarlo,
You have to implement a two pass strategy, in the first pass you build a variable with a XML fragment that contains the information you need then in the second pass to iterate on the variable sorting by totale_finale.
<item>
<totale_finale>
<xsl:value-of select="format-number($totale_finale,'#.##')" />
</<totale_finale>
<time1> other values you may need in your table </time1>
<time2> other values you may need in your table </time2>
<time3> other values you may need in your table </time3>
</item>
then you can use a for-each to loop on you variable "base"
Subject:sort by variable Author:Ivan Pedruzzi Date:11 Oct 2006 09:56 AM
Without see the entire code we can't say what is not working.
Here few comments
No need to define a template match="item", everything can be done in the main template match="/".
If you do want break down the code in different templates you have to call apply-templates and block the default template for text nodes using the following instruction