SAX2 RFD: LexicalHandler draft v.1.1

Paul Grosso pgrosso at arbortext.com
Wed Mar 24 19:48:17 GMT 1999


At 14:28 1999 03 24 -0500, David Megginson wrote:
>Bill la Forge writes:
> > Again, is anyone aware of why CDATA is preserved by the DOM?
> > What was the reasoning behind this decision? Other things, like
> > whitespace within an element tag or even attribute order, are not
preserved.
> > Why then was CDATA? 
>
>I would guess that the DOM WG believed that users of XML editors and
>repositories would want to see CDATA section boundaries and comments
>survive a round trip in and out of the tools.  Personally, I am
>extremely skeptical, but I have heard this argument many times from
>the employees of the vendors themselves.

As such a vendor, I hear this from our customers.  

When authoring a document, the user may want to know there
is a region into which s/he can paste stuff containing < and & 
characters and know they won't be interpreted as markup.  True,
the editing application can magically escape them (e.g., &lt;)
as part of the paste operation, but what if the user is using
Notepad to copy a parsable XML example into an XML document? 
Having to escape the special characters destroys the ability
to have that data remain parsable/validatable at the same time
as embedded in the larger document, and that destroys an important 
reuse/multipurpose feature otherwise available in XML.  (Think
of a dynamic XML document that allows you to "verify as well-formed"
the content of any <sample-xml> element in your tutorial document.)
 
The point is that the user-author inserted the CDATA section for 
a reason, and they might well want it to stay there.

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev at ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ and on CD-ROM/ISBN 981-02-3594-1
To (un)subscribe, mailto:majordomo at ic.ac.uk the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo at ic.ac.uk the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa at ic.ac.uk)




More information about the Xml-dev mailing list