【问题标题】:How to access XML data from SOAP web-service response in iPhone?如何从 iPhone 中的 SOAP Web 服务响应访问 XML 数据?
【发布时间】:2013-02-16 18:45:29
【问题描述】:

我正在使用 SOAP Web 服务,如果 Web 服务返回,我可以在其中读取字符串响应。但是当 web 服务返回一个字符串和一个 XML 时,我不知道如何访问这个 XML 响应。例如。

HTTP/1.1 200 正常 内容类型:文本/xml;字符集=utf-8 内容长度:长度

`

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <GetCountriesResponse xmlns="http://www.myurl.com/">
      <GetCountriesResult>
        <code>string</code>
        <profile>xmlxml</profile>
      </GetCountriesResult>
    </GetCountriesResponse>
  </soap:Body>
</soap:Envelope>`

在其中我不知道如何从 XML 访问这些代码和配置文件标记的响应。那你能建议怎么做吗?

【问题讨论】:

标签: iphone ios objective-c soap nsxmlparser


【解决方案1】:

请参阅SOAP Sample 上的 SOAP Turorial 可能对你有帮助

【讨论】:

    猜你喜欢
    • 2010-09-17
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2018-10-15
    • 1970-01-01
    相关资源
    最近更新 更多