This is according to the XML specification. All combinations of newline are
reduced to the 0x0A representation, for consistency across platforms. If you
want them to come out in some other form, you'll have to translate them as
they go out. This is something that probably a serializer should have an
option for.
--------------
Dean Roddey
Software Geek Extraordinaire
Portal, Inc
[EMAIL PROTECTED]
-----Original Message-----
From: Jonas Utterström [mailto:[EMAIL PROTECTED]]
Sent: Friday, May 04, 2001 7:46 AM
To: [EMAIL PROTECTED]
Subject: My \r characters disappears
Hi,
I create an XML document using Xerces DOM API. Then I write it to disk
using the DOMSerializer someone posted on this list. Some of my element
data contains DOS style newlines (\r\n). Using the serializer works and
the resulting textfile still keeps the DOS newlines intact. But when I
later parse the file with DOMParser it removes the \r and inserts a \n
character instead.
Created from scratch with DOM:
<kalle>My data\r\nMy data2</kalle>
Parsed:
<kalle>My data\n\nMy data2</kalle>
Bug, as intended or can I do a workaround for this problem?
I am currently using Xerces-c 1.4.0 on NT4.
/Jonas U
---------------------------------------------------------------------
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]