From: Elliotte Harold (firstname.lastname@example.org)
Date: Wed Jul 13 2005 - 05:24:11 CDT
Eric Muller wrote:
> XML does not require that in a CDATA section: "<![CDATA[x<y]]>" is a
> fine way to serialize the character content "x<y". Another fine point is
> that the character content ">" can be serialized as ">" or ">" in
> general, but must be serialized as ">" when it follows "]]" in a
> CDATA section (because ]]> marks the end of a CDATA section).
Not quite, though I think I've made this mistake in at least one of my
books. The CDATA section
<![CDATA[foo]]>bar]]> is parsed as the string "foo]]>bar", not
"foo]]>bar". There is no way to represent the three character sequence
]]> inside a CDATA section. You have to close the CDATA section, emit a
> character, and open a new CDATA section.
-- Elliotte Rusty Harold email@example.com XML in a Nutshell 3rd Edition Just Published! http://www.cafeconleche.org/books/xian3/ http://www.amazon.com/exec/obidos/ISBN=0596007647/cafeaulaitA/ref=nosim
This archive was generated by hypermail 2.1.5 : Wed Jul 13 2005 - 05:25:58 CDT