EDN Admin
Well-known member
Hi, Im trying to transform source XML to another XML structure that our system will accept. Im using the following link as a reference
http://www.w3schools.com/xsl/xsl_transformation.asp http://www.w3schools.com/xsl/xsl_transformation.asp .
<br/>
<br/>
The issue is that it seems to not show the XML in IE9 when I test it. It only renders the text as inline as if its not getting processed by the XSLT. Ive tried compatability mode as well with no luck. I thought I would see the "nice"
XML structure in the browser.
Heres my source XML with a reference to the XSLT file.
<?xml version="1.0" encoding="ISO-8859-1"?><br/>
<?xml-stylesheet type="text/xsl cdcatalogToXml.xsl"?>
<catalog><br/>
<cd><br/>
<title>Empire Burlesque</title><br/>
<artist>Bob Dylan</artist><br/>
<country>USA</country><br/>
<company>Columbia</company><br/>
<price>10.90</price><br/>
<year>1985</year><br/>
</cd><br/>
</catalog>
Heres the XSLT file:
<?xml version="1.0" encoding="ISO-8859-1"?><br/>
<xsl:stylesheet version="2.0" xmlns:xsl=" http://www.w3.org/1999/XSL/Transform http://www.w3.org/1999/XSL/Transform <br/>
<xslutput method="xml"/>
<xsl:template match="/ <br/>
<records><br/>
<xsl:for-each select="catalog/cd <br/>
<record><br/>
<title><xsl:value-of select="title"/></title><br/>
<artist><xsl:value-of select="artist"/></artist><br/>
</record><br/>
</xsl:for-each><br/>
</records><br/>
</xsl:template>
</xsl:stylesheet>
View the full article
http://www.w3schools.com/xsl/xsl_transformation.asp http://www.w3schools.com/xsl/xsl_transformation.asp .
<br/>
<br/>
The issue is that it seems to not show the XML in IE9 when I test it. It only renders the text as inline as if its not getting processed by the XSLT. Ive tried compatability mode as well with no luck. I thought I would see the "nice"
XML structure in the browser.
Heres my source XML with a reference to the XSLT file.
<?xml version="1.0" encoding="ISO-8859-1"?><br/>
<?xml-stylesheet type="text/xsl cdcatalogToXml.xsl"?>
<catalog><br/>
<cd><br/>
<title>Empire Burlesque</title><br/>
<artist>Bob Dylan</artist><br/>
<country>USA</country><br/>
<company>Columbia</company><br/>
<price>10.90</price><br/>
<year>1985</year><br/>
</cd><br/>
</catalog>
Heres the XSLT file:
<?xml version="1.0" encoding="ISO-8859-1"?><br/>
<xsl:stylesheet version="2.0" xmlns:xsl=" http://www.w3.org/1999/XSL/Transform http://www.w3.org/1999/XSL/Transform <br/>
<xslutput method="xml"/>
<xsl:template match="/ <br/>
<records><br/>
<xsl:for-each select="catalog/cd <br/>
<record><br/>
<title><xsl:value-of select="title"/></title><br/>
<artist><xsl:value-of select="artist"/></artist><br/>
</record><br/>
</xsl:for-each><br/>
</records><br/>
</xsl:template>
</xsl:stylesheet>
View the full article