iPhone 的 xml 解析错误
大家好,在我的 iphone 应用程序中发送登录 xml 请求后,我收到以下错误的 xml...但我无法理解错误是什么...
<?xml version="1.0" encoding="ISO-8859-1"?><SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/">
<SOAP-ENV:Body><SOAP-ENV:Fault><faultcode xsi:type="xsd:string">SOAP-ENV:Client</faultcode><faultactor xsi:type="xsd:string"></faultactor><faultstring xsi:type="xsd:string">error in msg parsing:
Charset from HTTP Content-Type 'UTF-8' does not match encoding from XML declaration 'ISO-8859-1'</faultstring><detail xsi:type="xsd:string"></detail></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>
Hello all in my iphone application after sending login xml request am getting following faulted xml... but i cant understand what the error is...
<?xml version="1.0" encoding="ISO-8859-1"?><SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/">
<SOAP-ENV:Body><SOAP-ENV:Fault><faultcode xsi:type="xsd:string">SOAP-ENV:Client</faultcode><faultactor xsi:type="xsd:string"></faultactor><faultstring xsi:type="xsd:string">error in msg parsing:
Charset from HTTP Content-Type 'UTF-8' does not match encoding from XML declaration 'ISO-8859-1'</faultstring><detail xsi:type="xsd:string"></detail></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
嗯,错误消息表明您尝试解析一个文档,其中文档标头表示该文档采用 ISO 8859/1 编码,而 HTTP 标头表示该文档采用 UTF-8 编码。解析器可以通过给予 HTTP 标头优先级来解决该冲突,但该解析器似乎选择不这样做。不一致意味着存在某种配置问题,需要进行调查。
Well, the error message is saying that you tried to parse a document where the document header said it was encoded in ISO 8859/1, while the HTTP header said it was in UTF-8. Parsers are allowed to resolve that conflict by giving the HTTP header precedence, but it seems this parser chose not to. The inconsistency means there's some kind of configuration problem and it needs to be investigated.