[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: xsl:sort now working under unix
Hi Anton,
that did help. this is of course the streamlined version to see if I could get sort working period. My more complicated real issue still does not work so there is probably a slightly different syntactical issue. In my real code, I am combining multiple xml files using: <?xml version="1.0"?> <?xml-stylesheet type="text/xml" href="./status_style.xsl"?> <runs> <title>Summary of CCSM Production Runs</title> <case filename="./b30.043.xml"/> <case filename="./b30.999.xml"/> <case filename="./b30.100.02.xml"/> </runs> the above is what I load in the browser.
<start_info>hybrid b30.999 year 100</start_info> <start_year>230</start_year> <proj_end_year> ?? </proj_end_year> <res>T45_gx1v3</res> <description>1870 Control</description> <working_group>NA</working_group> <tag>ccsm3_0_rel03</tag> <history> xlink to WREQ </history> <!--running, completed, halted, or aborted--> <status>aborted</status> <queue>csl_sp8</queue> </case> here is the stylesheet. I will need to be able to sort all these cases by various parameters in the xml files: <?xml version= "1.0"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:template match="/"> <html> <head> <title><xsl:value-of select="/runs/title"/></title> <link rel="stylesheet" type="text/css" href="/cseg/doc.css"></link> </head> <body> <h1> CCSM Production Run Status</h1> <table cellpadding="4" cellspacing="4" border="1"> <tr bgcolor = "#c6EFF7"> <td>Case</td> <td>Status</td> <td>Start Info</td> <td>Start Year</td> <td>End Year</td> <td>Resolution</td> <td>Tag</td> <td>Queue</td> <td>Description</td> <td>History</td> </tr> <xsl:for-each select="/runs/case"> <!--ascending or descending--> <xsl:apply-templates select="document(@filename)/case"> <xsl:sort select="/case/status" data-type = "text" order="descending"/> </xsl:apply-templates> </xsl:for-each> </table> </body> </html> </xsl:template>
</xsl:template> </xsl:stylesheet> Anton Triest wrote: Hi Sylvia,
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|