cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bentley, Tim" <TIM.BENT...@ca.com>
Subject RE: CDATA output
Date Wed, 11 Apr 2001 05:57:56 GMT
Depends what you're trying to do.  If the HTML is static, it's easier to put
it in a stylesheet rather than in your source XML page.  Alternatively you
can leave the HTML content in your XML page and use <xsl:copy> or
<xsl:copy-of> in a stylesheet to copy the HTML to the output XML file during
processing.  Check out a good XSL book or one of the XSL sites for more
details.

If the HTML is dynamic - ie it is being generated or loaded at run-time from
a database or similar - there are a couple of different things you can do.
I believe that Donald's esql taglib has the ability to grab XML from a
database record and add it to the XML output.  You can look at his source
code for ideas.



Tim Bentley

> -----Original Message-----
> From: e9625460@stud3.tuwien.ac.at [mailto:e9625460@stud3.tuwien.ac.at]
> Sent: Wednesday, 11 April 2001 2:48
> To: cocoon-users@xml.apache.org
> Subject: CDATA output
> 
> 
> 
> hi
> 
> little question: how can i prevent cocoon from quoting the HTML
> fragments stored in an CDATA section during output?
> 
> e.g. i use the following XML
> 
> ---------
> <value>
> <![CDATA[
> <ul>
> <li>testlist</li>
> </ul>
> ]]>
> </value>
> ---------
> 
> cocoon quotes all the <, > and & during output and the browser
> displays the code and doesnt interprate the HTML code which is
> stored in the CDATA.
> 
> disable-output-quoting doesnt work (i have consulted the faq!).
> 
> any ideas or work arounds?
> 
> TIA
> 
> 
> ---------------------------------------------------------------------
> Please check that your question has not already been answered in the
> FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
> 
> To unsubscribe, e-mail: <cocoon-users-unsubscribe@xml.apache.org>
> For additional commands, e-mail: <cocoon-users-help@xml.apache.org>
> 

---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail: <cocoon-users-help@xml.apache.org>


Mime
View raw message