【发布时间】:2013-11-19 05:50:36
【问题描述】:
我是 iPhone 和 SOAP XML 请求的新手。我正在使用 SOAP Web 服务从服务器获取响应。我收到以下响应:
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<AuthenticateResponse xmlns="http://tempuri.org/">
<AuthenticateResult>
<DocumentElement>
<Status>
<EMAIL>True</EMAIL>
<PASSWORD>true</PASSWORD>
</Status>
</DocumentElement>
</AuthenticateResult>
</AuthenticateResponse>
</soap:Body>
</soap:Envelope>
作为响应,没有得到开始和结束标记。这就是为什么在将其读取解析为字符串时,我无法获取 EMAIL 和 PASSWORD 的值。我正在使用 NSXMLParser 来解析响应。有什么方法可以转换吗? 请帮助我,在此先感谢。
【问题讨论】:
标签: ios iphone objective-c soap nsxmlparser