[Project_owners] XML Whitespace

Alex Vincent ajvincent at gmail.com
Sat Mar 26 21:55:38 EST 2005


> Just wondering what methods any of you use to get around Mozilla
> treating linebreaks as nodes in XML documents. Would it be easier to
> recursively parse through the whole thing upon loading and cut out all
> of them, or do you use a different approach?

I ended up writing a special pair of functions
(removeWhitespaceByNamespace, and removeWhitespace) to take care of
that.  My thinking is that you should discriminate between languages
intended to have white space text nodes, and those intended not to
have them.
-- 
"The first step in confirming there is a bug in someone else's work is
confirming there are no bugs in your own."
-- Alexander J. Vincent, June 30, 2001


More information about the Project_owners mailing list