Re: Removing namespaces without escaping CDATA???
I' trying to remove namespaces from a document using the following piece of code that although works, has the side-effect of escaping CDATA sections (eg. "<![CDATA[blah blah]]>").
I don't see why your stylesheet would escape the <![CDATA]> delimiters. What should happen is that CDATA sections are converted to normal text nodes so e.g.
<element><![CDATA[Kibo & Xibo]]></element>
would be transformed to
<element>Kibo & Xibo</element>
There is no generic way to preserve CDATA section with XSLT as you have to explicitly specify which elements are to be output as CDATA section in the result document using
So unless you author a stylesheet for a particular class of input documents where you know which elements have CDATA section content so that you can list them in the xsl:output cdata-section-elements attribute value I don't see a way to preserve CDATA sections.
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format