?
Solved

XML Transformation and CDATA Sections

Posted on 2001-06-04
2
Medium Priority
?
477 Views
Last Modified: 2013-11-23
I have an XML element which contains HTML text which is not well-formed. So I contained the HTML in a CDATA section. . I am running a transformation using XSL to convert my document into HTML to be viewed in a browser. The parsing and the transformation work fine, except that the markup characters within the CDATA section are being converted to entities, so the end viewer is seeing the HTML markup displayed in the browser instead of the results of that HTML. So if within the CDATA section the
XML doc reads <B>HELLO</B>, the transformation output is &lt;B&re;HELLO&lt;B&rt;

The question is, how do I get the transformer to maintain the HTML within the CDATA section without transforming the mark-up characters into entities?
0
Comment
Question by:tgoglia
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 12

Accepted Solution

by:
ahosang earned 800 total points
ID: 6154205
You need the attribute:
disable-output-escaping="yes" to be put in your <xsl:value-of> tag like:

<xsl:value-of select="whatever" disable-output-escaping="yes"/>
0
 

Author Comment

by:tgoglia
ID: 6157202
Thanks for the help.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction Since I wrote the original article about Handling Date and Time in PHP and MySQL several years ago, it seemed like now was a good time to update it for object-oriented PHP.  This article does that, replacing as much as possible the pr…
Introduction This article is the first of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article explains our test automation goals. Then rationale is given for the tools we use to a…
This video teaches viewers about errors in exception handling.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
Suggested Courses
Course of the Month12 days, 20 hours left to enroll

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question