[jdom-interest] disable-output-escaping

Fabrizio Lippolis Fabrizio.Lippolis at AurigaInformatica.it
Fri May 27 05:19:50 PDT 2005


Hi,

I have an XML in which a tag contains some HTML code protected by a
CDATA in this way:

<VBDESCRIPTION><![CDATA[aaa <font color="#009900">bbb</font> <font
style="BACKGROUND-COLOR: #0000ff">ccc</font>]]></VBDESCRIPTION>

This is processed by a XSL which should output the HTML code somewhere.
To perform this task I have found I have to write this way:

<xsl:value-of select="//*/VBDESCRIPTION" disable-output-escaping="true" />

The problem is the resulting HTML doesn't contain the expected result 
and shows a processing instruction like 
<?javax.xml.transform.disable-output-escaping?>

I am using JDOM b8 and I haven't upgraded because until now it was good 
for all my purposes, trying to upgrage to version 1.0 to see if this 
solves the problem lead me to compilation errors. I have also read in 
another mail (rather old anyway) that JDOM doesn't support 
disable-output-escaping, is it still true with version 1.0? If not I can 
  consider an upgrade. In this case what is the correct way to let the 
transformer interpret disable-output-escaping? Does it work out of the 
box or is it necessary to use some special classes/parameters? A little 
example would be greatly appreciated. Thank you very much in advance.

Fabrizio Lippolis


More information about the jdom-interest mailing list