<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml" indent="yes" version="1.0" />
<xsl:variable name="order" select="' textbox radio '"/>
<xsl:template match="Layout">
<taborder>
<fieldlist>
<xsl:apply-templates select=".//Box/*[(_at_)id]">
<xsl:sort select="substring-before($order,name())"/>
</xsl:apply-templates>
</fieldlist>
</taborder>
</xsl:template>
<xsl:template match="Box/*">
<field name="{(_at_)id}" tabindex="{position()}"/>
</xsl:template>
</xsl:stylesheet>
$ saxon box.xml box.xsl
<?xml version="1.0" encoding="utf-8"?>
<taborder>
<fieldlist>
<field name="textbox" tabindex="1"/>
<field name="textbox1" tabindex="2"/>
<field name="TextBox2" tabindex="3"/>
<field name="TextBox3" tabindex="4"/>
<field name="radio" tabindex="5"/>
</fieldlist>
</taborder>
________________________________________________________________________
This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________
--~------------------------------------------------------------------
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>
--~--