This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Re: Grooping and Sorting problem
- From: tanz at tmohammad dot fsnet dot co dot uk
- To: <xsl-list at lists dot mulberrytech dot com>
- Date: Thu, 28 Mar 2002 19:32:04 -0000
- Subject: Re: [xsl] Grooping and Sorting problem
- References: <BE207E4BF0B5F548A02A2D3AA968AB84117CB4@mail.he-networks.com>
- Reply-to: xsl-list at lists dot mulberrytech dot com
Hi Frédéric,
To sort your elements you can use the xsl:sort element:
For example:
<xsl:for-each select="root/test">
<xsl:sort
select="./@number"
data-type="number"
order="ascending"
/>
.......
</xsl:for-each>
Regards
Tanzila
----- Original Message -----
From: "Frédéric Tremblay" <ftremblay@eonmediainc.com>
To: <xsl-list@lists.mulberrytech.com>
Sent: Thursday, March 28, 2002 7:14 PM
Subject: [xsl] Grooping and Sorting problem
> > Hi, i want to make a HTML table with 5 column and n rows with a XML like
> > this:
> >
> > <root>
> > <test number="3">
> > <test number="1">
> > <test number="4">
> > <test number="2">
> > <test number="5">
> > ...
> > <test number="100">
> > </root>
> >
> > so i want to make a table with 5 column and n rows, at every 5 element
> > i want a new row.
> >
> > BUT THE PROBLEM IS: I NEED TO HAVE ALL ELEMENT SORTED!!!
> >
> > How can i do this?
> >
> > Thanks a lot!
> >
> > Fred
> >
>
> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
>
>
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list