 |
 |
 |
Hi,
> What I have learned from this forum is to be very precise
> when making an
> example to try to simplify a real life situation.
>
> In the real case the tags <A> to <E> are more like <Order1>
> to <Order5> and
> <a> to <e> are like <Show1> to <Show5>. That will make the
> use of uppercase
> / lowercase functions useless.
>
> <Root>
> </...>
> <Show1>10</Show1>
> <Show2>20</Show2>
> <Show3>30</Show3>
> <Show4>40</Show4>
> <Show5>50</Show5>
> </...>
> ...
> ...
> <Order1>3</Order1>
> <Order2>5</Order2>
> <Order3>1</Order3>
> <Order4>2</Order4>
> <Order5>4</Order5>
> </..>
> </Root>
>
> And it needs to be:
>
> <no>30</no>
> <no>40</no>
> <no>10</no>
> <no>50</no>
> <no>20</no>
In that case,
<xsl:template match="Root">
<xsl:for-each select="*[starts-with(name(), 'Order')]">
<xsl:sort select="." data-type="number"/>
<no>
<xsl:value-of select="../*[name() = concat('Show',
substring(name(current()), 6))]"/>
</no>
</xsl:for-each>
</xsl:template>
Oh-I-do-hate-flat-hunting-stressed-cheers,
Jarno - Madam Zu: March 2004
|
 | 

|  |
These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.
|  |
| |
 |
 |
 |