Subject: RE: [xsl] possible nested loops From: "Michael Kay" <mike@xxxxxxxxxxxx> Date: Wed, 15 Feb 2006 00:16:21 -0000 |
It sounds like a straightforward beginner's problem, but it's hard to know how to set you on the right path without seeing where you've gone wrong. I know you may find it embarrassing to show your novice code in public, but it's the best way of getting focussed advice. Nested for-each loops are one way to tackle this problem, but "the XSLT way" is a recursive descent of the tree structure using template rules that match the nodes at each level. Michael Kay http://www.saxonica.com/ > -----Original Message----- > From: garry@xxxxxxxxxxxxxxxxxxx [mailto:garry@xxxxxxxxxxxxxxxxxxx] > Sent: 14 February 2006 22:21 > To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx > Subject: [xsl] possible nested loops > > I wonder if someone could point me in the right direction to solve my > problem. I need to transform an xml file to html. I have > tried to make a > stylesheet but none of my efforts have been successful. > The xml has around 800 pupil records (<pupil>) so I want to > iterate over > each pupil node. Within each pupil node there are other nodes which > repeat, so for each pupil I need to iterate over child nodes of which > there may be none or many of each type. I suspect a nested > loop of some > sort may help but I have not been able to implement one, any ideas? > regards > garry
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] possible nested loops, George Cristian Bina | Thread | RE: RE: [xsl] possible nested loops, cknell |
RE: [xsl] Calling java in xsl., Michael Kay | Date | [xsl] Finding and processing index , Dan Vint |
Month |