任何哥们都可以在api的帮助下看到天气更新的任何代码,如果有任何哥们有任何教程,然后plz给予我..天气api,api for iphone,api for php
无论是iPhone或PHP的
thnks
任何哥们都可以在api的帮助下看到天气更新的任何代码,如果有任何哥们有任何教程,然后plz给予我..天气api,api for iphone,api for php
无论是iPhone或PHP的
thnks
使用谷歌是否在PHP
看到链接 http://komunitasweb.com/2009/09/showing-the-weather-with-php-and-google-weather-api/
实施到iPhone看老问题在这样:
https://stackoverflow.com/questions/1305127/free-weather-api
下面是一个PHP的例子(注:需要从openweathermap.org有效的API-KEY)
$url = 'http://api.openweathermap.org/data/2.5/forecast?q=London,us&mode=xml&appid=<API-KEY>'
$forecast = file_get_contents($url);
您可以通过城市得到预测名称,城市ID,纬度&经度等
我该如何解析它? – user874090 2010-12-23 07:29:30
你的意思是为PHP?你可以在链接中看到使用xpath的例子 – 2010-12-23 07:38:51