Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IP地址定位和天气接口 #19

Open
lensh opened this issue Aug 24, 2017 · 0 comments
Open

IP地址定位和天气接口 #19

lensh opened this issue Aug 24, 2017 · 0 comments

Comments

@lensh
Copy link
Owner

lensh commented Aug 24, 2017

一、IP地址定位
1.自动获取IP地址和地理位置:
(1) 接口1:http://1212.ip138.com/ic.asp
(2) 接口2(淘宝IP地址库):http://ip.taobao.com/ipSearch.php
2.通过IP地址获取地理位置
参考 http://ip.taobao.com/instructions.php ,可以得到以下接口
接口:http://ip.taobao.com/service/getIpInfo.php?ip=[ip地址字串]
二、天气接口
1.通过聚合数据,可以申请免费的天气接口
2.新浪的接口:http://php.weather.sina.com.cn/xml.php?city=%B1%B1%BE%A9&password=DJOYnieT8234jlsK&day=0
其中city是经过urlencode后的城市名称,如 北京->%B1%B1%BE%A9,会返回一个xml格式的数据

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant