Subject: Re: [xsl] Preventing CDATA output in XHTML From: "Alexander Johannesen" <alexander.johannesen@xxxxxxxxx> Date: Tue, 3 Jul 2007 15:49:45 +1000 |
so there is no native "xhtml".
Actually, this is a peculiar one that's libxslt specific as far as my investigation go. I struggled with this very problem a few weeks back, aiming for that picture perfect valid xhtml. All was going well until I hit <script>.
1. libxslt *will* treat method='xhtml' differently from both 'xml' and 'html'. This is not standard, but it certainly is there.
2. I haven't chased what the specifics are, but as to this conversation, making <script> an enforced CDATA section is the big one.
3. The enforcing CDATA is fine when you can't trust mere mortals to escape it themselves, nor does it cater to exceptions, which indeed putting // inside the element before the CDATA escaping is.
After much fiddling I revert to a dirty option ; I skipped the whole thing, processed as XML and used my programming language to insert // between <script> and CDATA. Dity, not what I'd prefer, but I do understand that these are exceptions.
Alex -- --------------------------------------------------------------------------- Project Wrangler, SOA, Information Alchemist, UX, RESTafarian, Topic Maps ------------------------------------------ http://shelter.nu/blog/ --------
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Preventing CDATA output i, Dale Tan | Thread | Re: [xsl] Preventing CDATA output i, Brian Koontz |
Re: [xsl] Preventing CDATA output i, Dale Tan | Date | Re: [xsl] Testing with MSXML 3.0 or, Joe Fawcett |
Month |