I am new to XSLT. I have a requirement where I need to convert an XML file to XSLT. In that, I need to iterate in a loop to get all the values from an XML like
<books>
<book-00>
<science price=""/>
.
.
.
<\book-00>
<book-01>
<english price=""/>
.
.
.
.开发者_运维问答
<\book-01>
<book-nn>
<\book-nn>
<\books>
How can I write a for loop with the dynamic count by reading it from an XML node into XSLT?
You try to avoid looping with XSLT, opting instead to use templates.
You need to apply an XSLT stylesheet to your XML in order to produce some sort of output (normally a different XML dialect, such as XHTML).
How this is done depends on the language and platform you are using - however, you have not indicated which ones you are using.
I suggest reading up on XSLT before you continue.
精彩评论