You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xerces.apache.org by St...@r2isante.fr on 2001/03/07 17:19:04 UTC
Réf. : RE: Serializing Node only
This works fine !!!
Thanks you for your help.
Stéphane
I hope this works
org.apache.xml.serialize.OutputFormat.setOmitXMLDeclaration()
XMLSerializer serial=new XMLSerializer(outstream,format);
serial.asDOMSerializer();// As a DOM Serializer
serial.serialize(doc.getDocumentElement());
-----Original Message-----
From: Stephane.RAULT@r2isante.fr [mailto:Stephane.RAULT@r2isante.fr]
Sent: Wednesday, March 07, 2001 4:56 PM
To: xerces-j-user@xml.apache.org
Subject: Serializing Node only
Hi all !
My goal is to put into a XML file that i produce from scratch a
CDATASection with a portion of XML into like this :
<foo>
<firstRealTag> blabla </firstRealTag>
<secondRealTag> blabla too </secondRealTag>
<setOfUnrealTags>
<![CDATA[
<firstUnrealTag> blibli </firstUnrealTag>
<secondUnrealTag> blibli too </secondUnrealTag>
]>
</setOfUnrealTags>
</foo>
I tought I can create my two "UnrealTags" in a DOM Tree and serialize
them
with a Serializer to create a CDATASection with.
But I can't manage to avoid the first line of the serializer : <?xml
version="1.0" encoding="UTF8"?>
Does anyone know how to avoid this ?
Cordialement,
-----------------------------------------
Stéphane RAULT
R2I-Développement
8, rue du blanc
14000 Caen
e-mail : stephane.rault@r2isante.fr
Tel : 02-31-29-32-40
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-user-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-user-help@xml.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-user-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-user-help@xml.apache.org