Re: [xml] Remove whitespaces from text nodes
- From: Liam R E Quin <liam holoweb net>
- To: spam spam spam spam free fr
- Cc: xml gnome org
- Subject: Re: [xml] Remove whitespaces from text nodes
- Date: Thu, 16 Feb 2012 08:40:31 +0100
On Thu, 2012-02-16 at 08:28 +0100, spam spam spam spam free fr wrote:
Anyway, there seems to have no other solution with libxml2 only.
The spaces are part of the text of the document, so it's not likely that
a conformant XML parser will strip them for you.
You could of course remove the spaces in C after parsing, just as if you
decided to remove every occurrence of an upper-case "B" from the input.
That's just standard C string processing.
Liam Quin - XML Activity Lead, W3C, http://www.w3.org/People/Quin/
Pictures from old books: http://fromoldbooks.org/
] [Thread Prev