Altova Mailing List Archives>Archive Index >microsoft.public.xsl Archive Home >Recent entries >Thread Prev - Re: Replace element text within xml >Thread Next - Re: Replace element text within xml Re: Replace element text within xmlTo: NULL Date: 9/1/2005 5:09:00 PM Dan Kelley wrote:
> Thanks for your help. However, I do not really understand your response as I
> know next to nothing about xslt. Could you please point me to an example that
> could help me on my way?
>
> Thanks
> Dan
>
I believe Dimitre means something like this
<!-- identity rule -->
<xsl:template match="node()|@*">
<xsl:copy>
<xsl:apply-templates select="@*"/>
<xsl:apply-templates/>
</xsl:copy>
</xsl:template>
<xsl:template match="test-suite">
<xsl:attribute name="testsuite">
<xsl:value-of select="."/>
</xsl:attribute>
</xsl:template>
<xsl:template match="test-suite">
<xsl:attribute name="testsuite">
<xsl:value-of select="."/>
</xsl:attribute>
</xsl:template>
<xsl:template match="test-case">
<xsl:attribute name="testcase">
<xsl:value-of select="."/>
</xsl:attribute>
</xsl:template>
I could be compltely wrong however. Try googling for 'xslt identity
rule', that's what I did.
john
| ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
