I've got a problem that's puzzling me:
 
What happens to XML comments when then appear above the document node, but after the XML processing instruction (and/or DOCTYPE line)?
 
My intuition would tell me that since comments can't exist outside of a document, they are ignored.  The reality is (at least in Xerces) that these aren't dropped but rather persist in the DOM document somewhere.
 
I'd like to be able to get at these comment nodes and change/remove them.
 
If I parse a document containing "heading comments" with the DOMParser and then serialize the document
produced by DOMParser.getDocument(), I end up with the same comments still in tact.
 
Is this supposed to happen?  Since they're kept, is there some way I can add comments before the document node?
 
Thank you.
 
Brion Swanson

--------------
Brion Swanson
Software Engineer (Co-op)
West Group - Public Records
[EMAIL PROTECTED]
716-327-6164 (x6164)

 

Reply via email to