I am new in C++ and cocos2d-x. I need to know how to parse XML with elements and attributes libxml2 in cocos2d-x . I have tried to google but I can't file any exact code example . how exactly are the usage of the libxml2 in cocos?
I found this code from the official site but I don't have any idea how to convert it into cocos code. http://www.xmlsoft.org/examples/reader1.c
I am using XCode for the IDE,.
If you look in CCSAXParser.cpp and CCUserDefault.cpp you will see an example of cocos2d-x using libxml to parse data. Or there is also this solution (I have never tried it).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With