Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: XSLT and Rows of Data

From: Marvin Smit <marvin.smit@-----.--->
To: NULL
Date: 8/3/2005 11:32:00 AM
Hi,

Yes it does. Its not entirely clear what piece you want from this but
here are some XPaths for the different sections (assuming no
namespaces).

XPath:
XmlNodeList allEmployees = xDoc.selectNodes("empl");
XmlNodeList allNames = xDoc.selectNodes("empl/emplName");


XSLT:

<xsl:template match="/>
     <xsl:apply-templates />
</xsl:template>

<xsl:template match="empl">
   <xsl:text>Employee name :</xsl:text>
   <xsl:value-of select="emplName" />
   <xsl:text>&#10;</xsl:text>
   <xsl:text>Employee ID :</xsl:text>
   <xsl:value-of select="emplId" />
   <xsl:text>&#10;</xsl:text>
   <xsl:text>Employee Login Dt :</xsl:text>
   <xsl:value-of select="emplLogInDt" />
   <xsl:text>&#10;</xsl:text>
</xsl:template>


Hope this helps,

Marvin Smit.


On 2 Aug 2005 07:50:39 -0700, "guevara_81@y..."
<guevara_81@y...> wrote:

<empl>
<emplName>Doe, John</emplName>
<emplId>1234</emplId>
<emplLogInDt>01/01/2005</emplLoginDt>
</empl>
<empl>
<emplName>Doe, John</emplName>
<emplId>1234</emplId>
<emplLogInDt>02/01/2005</emplLoginDt>
</empl>
<empl>
<emplName>Doe, John</emplName>
<emplId>1234</emplId>
<emplLogInDt>03/01/2005</emplLoginDt>
</empl>

>I hope that helps.  Thanks again.



transparent
Print
Mail
Digg
delicious
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent