ios - How to parse a SOAP response containing an XML Document inside the response tag -
i sending soap request server , getting following response. parsing response using ddxmlparser. however, parser interprets invalid xml. pretty sure data inside the<return>
tag has wrapped in [!cdata]
blocks. when parsing using nsxml parser
getting nsxmlparser error domain 64
. unsure how proceed now.
<?xml version="1.0" encoding="utf-8"?> <soapenv:envelope xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope"> <soapenv:body> <return> <?xml version="1.0"?> <catalog> <book id="bk101"> <author>gambardella, matthew</author> <title>xml developer's guide</title> <genre>computer</genre> <price>44.95</price> <publish_date>2000-10-01</publish_date> <description>an in-depth @ creating applications xml.</description> </book> <book id="bk102"> <author>ralls, kim</author> <title>midnight rain</title> <genre>fantasy</genre> <price>5.95</price> <publish_date>2000-12-16</publish_date> <description>a former architect battles corporate zombies, evil sorceress, , own childhood become queen of world.</description> </book> </catalog> </return> </soapenv:body> </soapenv:envelope>
any document can have 1 xml declaration , must @ beginning of document.
the parser see either nesting of documents or improper placement of xml declaration, both of cause error.
**<?xml version="1.0" encoding="utf-8"?>** <soapenv:envelope xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope"> <soapenv:body> <return> **<?xml version="1.0"?>** <catalog>
Comments
Post a Comment