Subject: [xsl] Sort and Variable From: Dan Diebolt <dandiebolt@xxxxxxxxx> Date: Mon, 23 Apr 2001 06:20:04 -0700 (PDT) |
You have numerous problems with your xsl - I don't know where to start other than to say you need to pick up a book or look over one of the on-line resources. The attached files accomplish what you described. Regards, Dan -------------------------------- File: AuthorSort.xml <?xml version="1.0"?> <?xml-stylesheet type="text/xsl" href="AuthorSort.xsl"?> <Authors> <Author rank="2"> <Name>Bar</Name> </Author> <Author rank="1"> <Name>Foo</Name> </Author> <Author rank="3"> <Name>Baz</Name> </Author> </Authors> File: AuthorSort.xsl <?xml version="1.0"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:template match="/"> <xsl:apply-templates select="Authors"/> </xsl:template> <xsl:template match="Authors"> <xsl:for-each select="Author"> <xsl:sort select="@rank"/> <xsl:value-of select="Name"/><br/> </xsl:for-each> </xsl:template> </xsl:stylesheet> __________________________________________________ Do You Yahoo!? Yahoo! Auctions - buy the things you want at great prices http://auctions.yahoo.com/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] Sort and Variable, Samuzeau Pascal | Thread | [xsl] XSL sheet Optimisation, Fr\id\iric SCHWEBEL |
Re: [xsl] XML source with DOCTYPE d, Wendell Piez | Date | Re: [xsl] XML source with DOCTYPE d, Zeljko Rajic |
Month |