This is an old implementation I did.
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="*">
<xsl:copy>
<xsl:apply-templates/>
</xsl:copy>
</xsl:template>
<xsl:template match="Items">
<Items>
<xsl:for-each select="Item">
<!-- sort item by category then sku, then copy results to output doc -->
<xsl:sort select="Category"/> <xsl:sort select="SKU"/> <xsl:copy-of select="."/> </xsl:for-each>
</Items>
</xsl:template>
</xsl:stylesheet>
I had used this in a pipeline to first sort my data, then format the results with a different stylesheet. Separating the processes immensely increased the overall speed.
-andy
Anna Bikkina wrote:
Can anyone please send me a snippet of how to use xsl:sort.
Anna.
On Wednesday 04 August 2004 08:38 am, [EMAIL PROTECTED] wrote:
On Wed, 4 Aug 2004, FREDERIC MOSER wrote:
Client side table sorting using javascript (like
http://brainjar.com/dhtml/tablesort/) is a really cool concept
but if
you have a lot of rows, your browser might get very slow and crash.
yes thats true, but in most cases so many rows that can crash or slowdown browser its not a good idea to be displayed to the user too.
i have no problem sorting some hundred rows (in IE).
-- stavros
i use microsoft's .htc behaviors to do think like that (work only on IE)
take a look here
http://tools.osmosis.gr/pubftp/table_sort/demo.html
ps --
every time i had to configure an .htc to work under cocoon i must to spend many hours :-(
-- stavros
---------------------------------------------------------------------I must admit I used brainjar's script pretty much "out of the box". I never succeed sorting hundred of rows with a reasonable speed (depends on what you're sorting of course...). But I still like the idea a lot so I would be curious to see how you're doing it.
Thanks in advance,
Fred
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
-- Andrew Stone [EMAIL PROTECTED] v) 678.385.2823 XML Architect/Developer Brightlane, a Teamstaff, Inc. Company
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
