xsl-list
[Top] [All Lists]

RE: How can I sort this?

2005-05-24 06:54:10


Andrew, use xsl:sort:


I think you've addressed this resonse to me rather than the original
poster :)


<?xml version="1.0" encoding="iso8859-1"?>
<xsl:stylesheet version="1.0" 
xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>
    <xsl:output method="xml" indent="yes"/>

    <xsl:template match="/">
        <select id="SmallElements">
            <xsl:apply-templates 
select="BigList/BigElement/SmallList/SmallElement">
                <xsl:sort select="Name"/>
            </xsl:apply-templates>
        </select>
    </xsl:template>

    <xsl:template match="SmallElement">
        <option value="{Code}">
            <xsl:value-of select="Name"/>
        </option>
    </xsl:template>

</xsl:stylesheet>

Regards,

--A

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



<Prev in Thread] Current Thread [Next in Thread>