This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Preserving XHTML markup


-- Michael Kay [Mon, 4 Feb 2002 20:11:18 -0000]:
>> this brings up an interesting question.
>>
>> which is preferred, using xsl:copy-of or putting the XML in
>> CDATA tags, and using value-of?

>If you have HTML that isn't well-formed, my preference is still to
>make it well-formed (use Dave Raggett's tidy) and then embed it directly,
>but in this case using CDATA is an alternative. The disadvantage is that
>you can then only copy it to the output, you can't transform it; and when
>copying it you have to use disable-output-escaping, which doesn't work if you
>want to use the result tree as input to another process, rather than
>serializing it immediately. (And specifically, it doesn't work for that reason with
>Netscape).

I suppose I've never actually had to do a secondary transformation on the content portion, which maybe is why I never thought of that scenario.  I tend to always encompass my HTML in CDATA, but in the future, I suppose I should simply use copy-of, and have the ability to transform the HTML too.

Thanks for everyone's help in clearing up my misconceptions.


---
Eric Vitiello
Perceive Designs
<www.perceive.net>


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]