• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 913
  • Last Modified:

Parse CDATA section in C++ using SAX

I am trying to parse CDATA section in my xml file using c++ and SAX parser.
Somehow it skipping the CDATA tag completely and I am unable to parse it.
Could you send me the snippet of code or so?
3 Solutions
Are you using SAX 1.0? SAX2 seems to be able to do that - see http://lists.xml.org/archives/xml-dev/199912/msg00232.html
pb_indiaAuthor Commented:
using SAX2
But its still skiping the the element CDATA

I wan tto know if I am setting the flags right
there is virtual void       startCDATA ()=0 in LexicalHandler Class of  Xerces-C++ library.

welcome to www.fruitfruit.com
I'd expect the data to appear as characters data without the CDATA escape characters. Are you not getting the CDATA content? If not, you might want to check that you've got the escape sequence right. Try looking at the XML document in IE to check its well-formedness.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now