Re: [xml] Remove whitespace in xml
- From: Malcolm Tredinnick <malcolm commsecure com au>
- To: xml gnome org
- Subject: Re: [xml] Remove whitespace in xml
- Date: Tue, 30 Sep 2003 14:16:25 +1000
On Tue, 2003-09-30 at 13:30, Manu M P wrote:
Hi
when i parsed the following xml
<A>
<B>
</B>
<C>
</C>
</A>
There are four child nodes below <A>. The parser Taken the white space characters between tag B and C ,
and c and A as a text nodes.
How can i remove those text nodes? . Is there any API?
One way is to do a quick parse through your tree and call
xmlIsBlankNode() on each text node. If that function returns true, you
can ignore / remove the node.
Malcolm
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]