I didnt put my code because it's quite simple:
 
// var value has here several '\n' and node is a DOMNode
 
  XMLCh *valueCh = XMLString::transcode(value);
 
  // if the node is not TEXT_NODE, the content is in the child TEXT_NODE
   node->setNodeValue(valueCh);
 
and now if I serialize to a formtarget the tree, the '\n' doen't appear.
 
 
----- Original Message -----
Sent: Wednesday, March 19, 2003 5:34 PM
Subject: RE: keep \n character

You might need to provide more details as to what you're doing, what you expect the result to be, and what's actually happening. Code and documents help. For instance, what do you mean "the tree doesn't keep them?" Are you inspecting nodes in memory, serializing to disk, and/or building a tree by parsing a document? Are you looking for <CR><LF> pairs, which XML specifies should be normalized to <LF> (I think)?
 
-----Original Message-----
From: Pablo Yabo [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 19, 2003 3:35 PM
To: xerces
Subject: keep \n character

Hi,
I'm creating a tree and when I add some text nodes that contains '\n' characteres the tree doesn't keep them.
How can I keep that characteres in the tree?
 
Pablo

Reply via email to