1

I had able to read the XML file using boost and writing the same content to another file .

<data>
<![CDATA[This is Test]]>
<prod name= "p1"/>
</data>

while writing to another file this would changes to below format.

<data>
This is Test
<prod name= "p1"/>
</data>

Here unformatted texts like Is missing in the output file.

can some one help on how to write the exact as format for unformatted texts like ?

sehe
  • 374,641
  • 47
  • 450
  • 633
Munipratap
  • 529
  • 5
  • 9

1 Answers1

0

Boost does not have an XML parser.

Boost Property Tree /uses/ an XML parser to... implement property tree persistence.

The XML parser it uses under the hood is a version of RapidXML.

RapidXML does support CDATA: RapidXML giving empty CDATA nodes

I doubt Property Tree uses it.

Community
  • 1
  • 1
sehe
  • 374,641
  • 47
  • 450
  • 633