[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: using xsl:output-character to render characters in

Subject: Re: using xsl:output-character to render characters in 2 ways
From: David Carlisle <davidc@xxxxxxxxx>
Date: Wed, 23 Dec 2009 15:48:18 GMT
Re:  using xsl:output-character to render characters in
> I think I do need to do it. I cannot serve html as this would break my
> company's accessibility guidelines (eg unclosed img tags)

companies may have all kinds of guidelines, and sometimes thay have to
be followed, the guidelines can be wrong though.

> 1. I need to create a '<![CDATA[]]>' section in the output
> (http://javascript.about.com/library/blxhtml.htm explains why)

the quoted page is misleading, it says:

> This fixes the validator. The problem is that some older web browsers
> don't understand the CDATA tag 

That implies that understanding <!CDATA[ markup is something fixed in
newer browsers, but that is misrepresenting the situation. You can not
have a CDATA section (or any markup) in a script element in HTML. The
age of the browser is immaterial. Conversely if you generate XHTML and
serve it as XHTML then CDATA quoting is understood by the browser.  So
problems only occur if you generate XHTML and serve it as HTML. That
generates syntax errors but commenting out odd lines only masks some of
the problems, basically the whole document is then in error.

Probably I haven't convinced you and you'll want to do this anyway, in
which case, I'd use Martin's suggestion of writing the script to an
external file.


Current Thread


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.