Subject: Re: [xsl] testing for child node and counting From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx> Date: Wed, 06 Feb 2002 17:13:28 -0500 |
<Orders> <Row att="..."> <field_a>...</field_a> <field_b>...</field_b> </Row> <Row att="..."> <field_a>...</field_a> <field_b>...</field_b> <field_c>...</field_c> </Row> ... </Orders>
1. I want to go through each <row> and create an html table row only if <row> contains a <field_c> child. I've tried this but it didn't work:
<xsl:for-each select="Orders/Row"> <xsl:if text="Orders/Row/field_c">
<tr> <td><xsl:value-of select="field_c"/></td> </tr>
</xsl:if> </xsl:for-each>
2. I want to print at the top of the html table the number of <row>s that have a <field_c> child.
I hope that helps, Wendell
====================================================================== Wendell Piez mailto:wapiez@xxxxxxxxxxxxxxxx Mulberry Technologies, Inc. http://www.mulberrytech.com 17 West Jefferson Street Direct Phone: 301/315-9635 Suite 207 Phone: 301/315-9631 Rockville, MD 20850 Fax: 301/315-8285 ---------------------------------------------------------------------- Mulberry Technologies: A Consultancy Specializing in SGML and XML ======================================================================
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] testing for child node an, David Carlisle | Thread | Re: [xsl] testing for child node an, alex |
Re: [xsl] testing for child node an, David Carlisle | Date | [xsl] meta tag, Charly |
Month |