In iOS development, although the current use of the mainstream data format is JSON, but sometimes encounter XML data format, we have to bite the bullet to parse, there are many third-party libraries such as afnetworking
Can also be taken to parse the XML, but because there will be a few callback methods, I myself feel not very convenient, some trouble, so used to another third-party class: Gdataxmlnode.h/m
Below is a brief introduction to how to use the Gdataxmlnode third party class
1. First go online to download this third party class, add to your project inside.
2.target-->build settings-->header Search Paths, double-click after dot +, and then add/USR/INCLUDE/LIBXML2, as
Find the other Linker Flags corresponding to the value in linking:-LXML2, as
3. Start a real request for XML data and resolve it, for the user experience, to open asynchronous threads when requesting data
4. After the real data source is available, we can configure the data where it is needed, and we hope to help you.
IOS questions about XML parsing