[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

<xsl:sort> not working under Unix

Subject: <xsl:sort> not working under Unix
From: Shaun Lizzio <shaun.lizzio@xxxxxxxxxxx>
Date: Fri, 1 Jun 2001 14:43:23 +0100
shaun lizzio
Hello,

I need some help with some XSL sorting code.
Im trying to reverse sort a list of nodes, before processing them using the
Xalan Java 1 XSLT processor.

The code i have used is detailed below and works when i try it in DOS, but
when its sent to a Unix server, it doesn't work. No errors are produced, but
the order is not reversed. Both processor versions are identical, and the
only thing that is different is the platform.

Ide really appreciate knowing why this is so? Thanks in anticipation.

The XSL and XML fragmemts are listed here...

XSL FRAG:

<!-- OUTPUT 'CHECK FOR MORE ON' KEYWORDS -->
<xsl:text>CHECK FOR MORE ON:
</xsl:text>
<xsl:for-each select="/story/nitf/head/docdata/key-list/keyword">

   <xsl:sort select="position()" data-type="number" order="descending">

   <xsl:variable name="alert_name" select="@key"/>
   <xsl:value-of select="@key"/>
   <xsl:text>http://www.someurl.com/</xsl:text>
   <xsl:choose>
      <xsl:when test="string-length(//category)=0">
         <xsl:text>news</xsl:text>
      </xsl:when>
      <xsl:otherwise>
         <xsl:value-of select="/story/properties/category"/>
      </xsl:otherwise>
   </xsl:choose>
   <xsl:text>/index.html?keywords=</xsl:text>
   <xsl:value-of select="translate($alert_name, ' ', '+')"/>
   <xsl:text>

</xsl:text>
</xsl:for-each>


XML frag
...
...
    <key-list>
       <keyword key="Newsflash update"/>
       <keyword key="UK"/>
       <keyword key="Crime"/>
       <keyword key="Attacks"/>
       <keyword key="Race issues"/>
    </key-list>
...
....

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.