> If I understand what you're trying to do, I believe you can do it in
XSLT 1.0 if your processor supports exsl:node-set() or a similar
extension (see www.exslt.org):
<xsl:variable name="my-sort-order">
<rabbit/>
<cat/>
<dog/>
</xsl:variable>
<xsl:template match="root">
<xsl:for-each select="*">
<xsl:sort select="count(exsl:node-set($my-sort-order)/*[name() =
name(current())]/preceding-sibling::*)" data-type="number"
order="ascending"/>
<xsl:copy-of select="."/>
</xsl:for-each>
</xsl:template>
--
Robin Johnson
rj at robinjohnson dot f9 dot co dot uk -
http://www.robinjohnson.f9.co.uk
It worked! Thanks for your help.
How did you come up with this solution? I'm having a difficult time with
XSLT and I'm wondering how did you come up with this interesting solution.
Does one need to read the XSLT spec or is there a real good book that
explains XSLT. I consider myself a very technical person (I know several
programming languages) but XSLT just kicks my butt. If no one answered my
question, I was going to re-write my XSLT in C# or C++ to get the job the
done. Thanks again for your help.