Altova Mailing List Archives>Archive Index >microsoft.public.xml Archive Home >Recent entries >Thread Prev - question about create table by using xslt >Thread Next - Re: question about create table by using xslt Re: question about create table by using xsltTo: NULL Date: 6/1/2007 9:33:00 AM
it'd be something like that:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="html" encoding="windows-1250"/>
<xsl:template match="/">
<html>
<body>
<hr/>
<div>Label <xsl:apply-templates select="/*/Product"/></div>
<hr/>
<div>Height <xsl:apply-templates
select="/*/Product/SpecList/Spec/SpecLabel[.='Height']"/></div>
<div>Width <xsl:apply-templates
select="/*/Product/SpecList/Spec/SpecLabel[.='Width']"/></div>
<div>Weight <xsl:apply-templates
select="/*/Product/SpecList/Spec/SpecLabel[.='Weight']"/></div>
</body>
</html>
</xsl:template>
<xsl:template match="Product">
<xsl:value-of select="name()"/>
<xsl:text> </xsl:text>
<xsl:value-of select="@id"/>
<xsl:text> </xsl:text>
</xsl:template>
<xsl:template match="SpecLabel">
<xsl:value-of select="../SpecValue"/>
<xsl:text> </xsl:text>
</xsl:template>
</xsl:stylesheet>
--
td
www.paranoja.org
| ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
