Problems with the xsl element ----<xsl:output method="xml"/>----
843834Aug 30 2007 — edited Sep 4 2007Hy, my problem is the next, I am trying to read a xml file and transform it in itself but when I do with XSLT, Internet Explorer doesnt show a xml file, just show me the text nodes of the xml file. I have the element <xsl:output method="xml"/>" in the xsl file but I dont Know what Iam doing wrong.
The next code is from the xsl file:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml"/>
<xsl:template match="/">
<xsl:copy-of select="catalog"/>
</xsl:template>
</xsl:stylesheet>
The next code is from the xml file:
<?xml version="1.0" encoding="UTF-8"?>
<!-- Edited with XML Spy v2007 (http://www.altova.com) -->
<?xml-stylesheet type="text/xsl" href="PlantillaXSL.xml"?>
<catalog dni="4546545">
<cd numero="2" id="5" color="red">
<title>Empire Burlesque</title>
<artist>Bob Dylan</artist>
<country>USA</country>
<company>Columbia</company>
<price>10.90</price>
<year>1985</year>
</cd>
</catalog>
The result in internet explorer is:
Bob Dylan USA Columbia 10.90 1985