Subject: RE: [xsl] Dynamical work with child nodes From: Roland Juergens <roland_juergens@xxxxxxxxxxxx> Date: Tue, 6 Apr 2004 16:08:34 +0200 |
and how can i access a subelement without using its name ? -----Original Message----- From: Andrew Curry [mailto:andrew.curry@xxxxxxxxxxxx] Sent: Dienstag, 6. April 2004 15:48 To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Subject: Re: [xsl] Dynamical work with child nodes <xsl:for-each select="//row"> </xsl:for-each> will go through all rows in your document ----- Original Message ----- From: "Roland Juergens" <roland_juergens@xxxxxxxxxxxx> To: <xsl-list@xxxxxxxxxxxxxxxxxxxxxx> Sent: Tuesday, April 06, 2004 2:46 PM Subject: [xsl] Dynamical work with child nodes > Hi, > > I have an XML file like this which contains results from a database query. > Is there a way to go dynamically through the subelements of my "row" > elements, because I want to use it for different queries. > So the subelements like "id" or "name" might change. > > <root> > <rowset> > <row> > <id>1</id> > <name>bla</name> > </row> > <row> > <id>2</id> > <name>blabla</name> > </row> > > ...(more <row> elements)... > > </rowset> > </root> > > > This is how the xsl-file looks like now > > ... > <xsl:for-each select="root/rowset/row"> > ... > <xsl:value-of select="id"/> > ... > <xsl:value-of select="name"/> > ... > </xsl:for-each> > ... > > > > What I imagine is the following : > I want to get the number of subelements of a "row" element, then iterate > over it to get the names, and then building it dynamical. > Is something like that possible ? > > > Roland Juergens
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Dynamical work with child, Mukul Gandhi | Thread | RE: [xsl] Dynamical work with child, G. Ken Holman |
RE: [xsl] How to put space between , Andrew Welch | Date | RE: [xsl] Dynamical work with child, G. Ken Holman |
Month |