Jason Stewart wrote:
Hey Lev,
I'm forwarding your query to the Xerces-C guys - maybe there is
something different with how Xerces is implementing the DOM3 API?
No, this is the expected behavior. The value of that element node is the
value of its text node child. You can also call DOMNode::getTextContent().
Dave
Cheers, jas.
---------- Forwarded message ----------
From: Lev Lvovsky <[EMAIL PROTECTED]>
Date: Jun 26, 2007 5:43 AM
Subject: getting element text?
To: [EMAIL PROTECTED]
I'm addmitedly new to DOM, but I'm a bit confused by what should seem
to work based on the W3 DOM tutorial.
if I have a Xerces::DOMElement, and I want to get the value of that
element, one would assume that getNodeValue would get me the text
string within the element tags:
<Element>Some Text</Element>
So if I have a DOMNode where getNodeType() returns 1, and getNodeName
returns 'Element', shouldn't getNodeValue return 'Some Text'? I'm
consistently getting emtpy strings for any Element that I use the
getNodeValue method on. getTextContent gives me the text, however I
would think that that's the wrong way to go about things.
Any help would be appreciated!
thanks,
-lev
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]