Subject: Re: [xsl] sorting by date From: David Carlisle <davidc@xxxxxxxxx> Date: Tue, 24 Jul 2001 16:02:45 +0100 |
> So where, and how, do i include your xsl:sort tag? You don't:-) In this version you are not using a for-each or an apply-templates to construct a current node list which you then process, you are selecting your items one at a time and moving around the soutce "by hand" with select="RetrieveTransactionHistory2RSResponse/Items/Item[position()=$ThisRec ord]/Date" /> so you never (as far as I can see) ever select more than one node at a time so you can't use xsl:sort. Most likely the easiest thing to do is sort forst into a temporary variable <xsl:variable name="x"> <RetrieveTransactionHistory2RSResponse><Items> <xsl:for-each select="RetrieveTransactionHistory2RSResponse/Items/Item"/> <xsl:sort ... <xsl:copy-of seelct="."/> </xsl:for-each> </Items></RetrieveTransactionHistory2RSResponse> </xsl:variable> then apply the templates you have got already using <xsl:apply-templates select="xx:node-set($x)/RetrieveTransactionHistory2RSResponse"/> where xx:node-set() is your processors node-set extension function. David _____________________________________________________________________ This message has been checked for all known viruses by Star Internet delivered through the MessageLabs Virus Scanning Service. For further information visit http://www.star.net.uk/stats.asp or alternatively call Star Internet for details on the Virus Scanning Service. XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] sorting by date, Daniel Newman | Thread | Re: [xsl] sorting by date, Jeni Tennison |
RE: [xsl] generating XML, Michael Kay | Date | RE: [xsl] sorting by date, Paul_B_Grimes |
Month |