View topic - Query about XmlParser libxmlnode

Query about XmlParser libxmlnode

General Help about QNX

Query about XmlParser libxmlnode

Postby madhav.agarwal » Wed Mar 10, 2010 1:40 pm

Hello,
I am using libxml parser to parse an xml file using API's of xmlnode.h. My xml file contains special characters of xml ("&","<",">", etc)
which are replaced by entity references. My problem is ,When i parse my file for the first time,the file is parsed successfully but once we save the document after parsing the file , it replaces "&amp;" to original character "&".This in turn corrupts the xml file and hence next time the file is not successfully loaded by the parser.

Please help in resolving this issue. If libxml.a is open source then can anyone tell me how can i get its source code.


Thanks in advance.
madhav.agarwal
Active Member
 
Posts: 23
Joined: Wed Jul 15, 2009 4:52 am

RE: Query about XmlParser libxmlnode

Postby maschoen » Wed Mar 10, 2010 5:31 pm

On QNX you can use pkgsrc to get the libxml source. You could just Google "libxml source" and that would turn it up quickly too. If you want to know how to write back &amp; as &amp; then I think you need to research libxml a little bit more.
maschoen
QNX Master
 
Posts: 2724
Joined: Wed Jun 25, 2003 5:18 pm

RE: Query about XmlParser libxmlnode

Postby mario » Wed Mar 10, 2010 8:42 pm

mario
QNX Master
 
Posts: 4132
Joined: Sun Sep 01, 2002 1:04 am

RE: Query about XmlParser libxmlnode

Postby maschoen » Thu Mar 11, 2010 4:05 am

:-) Oh Mario, please keep me laughing. :-)
maschoen
QNX Master
 
Posts: 2724
Joined: Wed Jun 25, 2003 5:18 pm

RE: Query about XmlParser libxmlnode

Postby madhav.agarwal » Thu Mar 11, 2010 9:56 am

Hello,
I have tried to search libxml source on google, but all the searched links are for libxml2, which is entirely different from libxml. Please tell me any specific link to download "libxml" sourcecode.Libxml2 does not support "xmlnode.h" API's which we were using with "libxml". So can u please tell me how to download the source code that supports the API's provided by "xmlnode.h".


Thak you
madhav.agarwal
Active Member
 
Posts: 23
Joined: Wed Jul 15, 2009 4:52 am

RE: Query about XmlParser libxmlnode

Postby mario » Thu Mar 11, 2010 12:31 pm

Maybe ? ftp://ftp.gnome.org/pub/GNOME/sources/libxml/

that gives me an idea, school should start offering courses in google search, that should become quite popular and useful.
mario
QNX Master
 
Posts: 4132
Joined: Sun Sep 01, 2002 1:04 am

RE: Query about XmlParser libxmlnode

Postby madhav.agarwal » Fri Mar 12, 2010 6:36 am

Hi,
I have seen ftp://ftp.gnome.org/pub/GNOME/sources/libxml/ .This is the version of libxml which does not have support for "xmlnode.h" API's which we are using in our application as mentioned on QNX website. Can you please suugest, how do i get the source code of "libxml" which suppports "xmlnode.h".

Examples of API we are using::

1. xml_node is used for storing XML Node.
2. XML_DocumentInit() method is used for Initializing the document.
3. XML_DocumentLoad() method is used to load the document.
4. XML_GetFirstNode() is used to get the forst Child node of Parent node.

Above mentioned API's are present in "xmlnode.h".

Thanks.
madhav.agarwal
Active Member
 
Posts: 23
Joined: Wed Jul 15, 2009 4:52 am

RE: Query about XmlParser libxmlnode

Postby mario » Fri Mar 12, 2010 5:23 pm

As per the QNX documentation libxml.a is version 1.1 of the ExpatXML Parser. Hopefully you that will help you narrow down your search.

For all my XML need I use C++ Poco library.
mario
QNX Master
 
Posts: 4132
Joined: Sun Sep 01, 2002 1:04 am


Return to Help

Who is online

Users browsing this forum: No registered users and 2 guests

cron