Altova Mailing List Archives>Archive Index >microsoft.public.xsl Archive Home >Recent entries >Thread Prev - xml to xml problem [Thread Next] Re: xml to xml problemTo: NULL Date: 7/12/2005 9:48:00 PM I use MSXML and have done this, however in addition to specifiying the
output as XML, I had to also place the XML elements/nodes into the XSL
stylesheet.
This means that the XSL template has elements, just like the HTML
elements you place into the stylesheet when you want the output in HTML
format.
look at the <xsl:element> and place it in the output "around" the
node's text/data just like you would when outputting to HTML...
<?xml version="1.0"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform" >
<xsl:output method="xml" indent="yes"/>
<xsl:template match="ALS">
<xsl:element name="Attribute">
<xsl:attribute name="name" >
<xsl:value-of select="name"/>
</xsl:attribute>
</xsl:element>
</xsl:template>
</xsl:stylesheet>
| ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
