解析仅巴黎的Google天气数据时出现问题 [英] Problem parsing Google weather data only for Paris

查看:119
本文介绍了解析仅巴黎的Google天气数据时出现问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经使用此 http://www.google创建了一个天气预报应用程序.com/ig/api?weather = paris .它适用于除巴黎以外的所有城市.

I have created an app for weather reports by using this http://www.google.com/ig/api?weather=paris. It works well for all cities except Paris.

在我的应用中,我有一个文本字段;如果我输入"Sydney",它将显示悉尼的天气, 但是如果我输入"Paris",则会出现错误:NSXMLParserErrorDomain error:9.我不知道这是什么意思可能是什么错误?有什么主意吗?

In my app I have a text field; if I type "Sydney", it will show the weather in Sydney, but if I type "Paris", it gives an error: NSXMLParserErrorDomain error:9. I don't know what it means. What could be the error? Any idea?

推荐答案

根据

According to Apple's documentation it has encountered an illegal character: NSXMLParserInvalidCharacterError = 9,

确保您将其正确解析为UTF-8

Make sure you correctly parse this as UTF-8

这篇关于解析仅巴黎的Google天气数据时出现问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆