Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


preserving markup

From: David Schwartz <davids58@-----.--->
To: NULL
Date: 6/6/2008 12:05:00 PM
I've got some javascript and HTML I want to enter directly into my xml
document. I've entered the JS and HTML content into a tag that's
defined as text in the schema. When I process my xml, the > and < in
the JS and HTML are output as named entitles &lt; and &gt;. As a
result, this content is interpreted by the browser as page content
rather than code/markup to be processed and rendered.

I've tried using just the non-escaped content as well the following
templates but the named entities always appear in the output.

  <xsl:template match="code">
      <div style="MARGIN-LEFT: 30px">
         <xsl:text disable-output-escaping="yes">&lt;![CDATA[ </
xsl:text>
            <xsl:value-of select="."/>
	       <xsl:text disable-output-escaping="yes">]]&gt;</xsl:text>
      </div>
</xsl:template>

  <xsl:template match="code">
      <div style="MARGIN-LEFT: 30px">
          <xsl:value-of select="."  disable-output-escaping="yes"/>
      </div>
</xsl:template>

Any help would be appreciated!!

TIA,
David


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent