You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@ws.apache.org by Duffiana Jones <cd...@polydeme.fr> on 2001/06/11 15:54:29 UTC

Re: Xerces parser 1.2.3 strangeness...

IMHO all parsers I know behave this way, and I even think it's a part of
the DOM specs.

duf.


Ryan Alexander a écrit :
> 
> I have a SOAP installation under J-Run.
> 
> I installed the Xerces parser version 1.2.3 as I understand that's the
> appropriate one to use.
> 
> I was testing it with just some XML handling and I noticed something
> really *weird*
> 
> It appears that if you put your values in the XML document in between
> the tags (as opposed to an attribute) it considers that text to be a
> child node of the named tag.
> 
> In other words where:
> 
> String title =
> tempE.getElementsByTagName("title").item(0).getNodeValue();
> 
> Would seem appropriate, instead:
> 
> String title =
> tempE.getElementsByTagName("title").item(0).getFirstChild().getNodeValue
> ();
> 
> Is required.
> 
> Could someone confirm that this is the case?
> 
> Would anyone know why it would behave this way?
> 
> -Ryan
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: soap-user-unsubscribe@xml.apache.org
> For additional commands, email: soap-user-help@xml.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: soap-user-unsubscribe@xml.apache.org
For additional commands, email: soap-user-help@xml.apache.org