Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Howto embed html in xml doc? Cdata? disable-output-escaping?

From: "Anthony Jones" <Ant@------------.--->
To: NULL
Date: 8/10/2006 2:47:00 PM


"Marianne" <bogus@n...> wrote in message
news:ODKHtqAvGHA.4888@T......
> How does one embed html in the xml doc and have it render as html? The
tags
> are being rendered as text (ie tags are escaped) - see output below.  Any
> help would be very appreciated!!!

Works fine for me. What tools are you using.

I added

<?xml-stylesheet type="text/xsl" href="test.xsl" ?>

To the xml file and opened it in Internet Explorer. Displayed as expected
Bold then underlined test.

The xmlns on the html tag is a liitle odd though why is that there?

>
> ex xml file:
>
> <?xml version="1.0" encoding="UTF8" ?>
> <test>
>   <![CDATA[<b>test</b>&nbsp;<u>test</u>]]>
> </test>
>
> ex xslt:
>
> <?xml version="1.0" encoding="US-ASCII" ?>
>   <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
> version="1.0">
>   <xsl:output method="html" omit-xml-declaration="no" indent="yes" />
>     <xsl:template match="test">
>   <html xmlns="http://www.w3.org/1999/xhtml">
>   <head>
>   <title></title>
>   <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"
/>
>
>       <xsl:value-of select="." disable-output-escaping="yes" />
>   </head>
>   </html>
>   </xsl:template>
> </xsl:stylesheet>
>
> output:
> <b>test</b>&nbsp;<u>test</u>
>
>




transparent
Print
Mail
Digg
delicious
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