重複の可能性:
iPhone/iOS JSON 解析チュートリアル
Web サイトから JSON データを解析する方法がわかりません。
{
"weather": {
"curren_weather": [
{
"humidity": "54",
"pressure": "1011",
"temp": "50",
"temp_unit": "f",
"weather_code": "1",
"weather_text": "Partly cloudy",
"wind": [
{
"dir": "W",
"speed": "9",
"wind_unit": "kph"
}
]
}
],
私がやりたいことは、「temp」変数と「weather_text」変数を NSStrings として保存して、ラベルなどで使用することです...
実際のリクエスト URL は次のようなものです: http://www.myweather2.com/developer/forecast.ashx?uac=(access-key)&output=json&query=(latitude,longitude)&temp_unit=f
これを完了する方法について何か考えはありますか?