OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Stripping leading and trailing spaces???

[ Lists Home | Date Index | Thread Index ]
  • From: David Megginson <david@megginson.com>
  • To: "XML Developers' List" <xml-dev@ic.ac.uk>
  • Date: Tue, 2 Feb 1999 19:39:57 -0500 (EST)

Dan Finkelstein writes:

 > It seems that leading and trailing spaces are being removed from
 > PCDATA before it is returned to me.  For example,
 > 
 > 	<text>  Hello there!  </text
 > 
 > comes back as "Hello there!" instead of " Hello there!  ".  I'm
 > using Sun's early release parser, and I'm wondering if this is
 > standard XML behavior? if there is a way to preverse the spaces?

Which interface are you using?  If you're using SAX, it could be that
the spaces are being delivered in separate characters() events
(parsers are allowed to chunk up character data any way they want).


All the best,


David

-- 
David Megginson                 david@megginson.com
           http://www.megginson.com/

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To (un)subscribe, mailto:majordomo@ic.ac.uk the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo@ic.ac.uk the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa@ic.ac.uk)





 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS