cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 27275] - xsl:sort not sorting correctly
Date Thu, 26 Feb 2004 23:50:13 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=27275>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=27275

xsl:sort not sorting correctly





------- Additional Comments From khanh.vo@antin.com  2004-02-26 23:50 -------
Here is a sample content
XML:
<Document id="pm_Individual_3">
  <Para>3:three</Para>
  <Para>2:two</Para>
  <Para>1:one</Para>
</Document>

XSL:
<xsl:for-each select="Para">
<xsl:sort data-type="number" select="substring-before(current(),':')"/> 
  <p class="MsoBodyText">
    <span style="font-family:&quot;Times New Roman&quot;">
      <xsl:value-of select="substring-after(current(),':')"/>
    </span>
  </p>
</xsl:for-each>

Output:

three  

one  

two

Mime
View raw message