|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Wrapping XSL around XML tags of the same name
I'm hoping someone can shed some light on this problem.
I have to wrap an XSL style sheet around some XML which is produced from a
stored procedure in a SQL database. It is producing XML as shown below:
<journey>
<outbound>
<start_time>
<time value="0825"/>
<time value="0925"/>
<time value="1025"/>
</start_time>
</outbound>
</journey>
My question is basically, how would I wrap XSL around the individual tags?
For example, if the output was:
<journey>
<outbound>
<start_time>
<time_1 value="0825"/>
<time_2 value="0925"/>
<time_3 value="1025"/>
</start_time>
</outbound>
</journey>
I could just use the following to individually access each attribute:
<xsl:value-of select="journey/outbound/start_time/time_1@value" />
<xsl:value-of select="journey/outbound/start_time/time_2@value" />
<xsl:value-of select="journey/outbound/start_time/time_3@value" />
How would I go about this where the time tag is not unique?
All help is greatly appreciated!
Thanks in advance
John :-)
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








