jquery中调用天气预报API(ajax)

2025-06-24 16:51:51
推荐回答(2个)
回答1:

$.getScript('http://int.dpool.sina.com.cn/iplookup/iplookup.php?format=js', function(_result) {
if (remote_ip_info.ret == '1') {
$.ajax({
type: "GET",
url: "http://wthrcdn.etouch.cn/weather_mini?city="+remote_ip_info.city,
data: "",
success: function(msg){
console.log(msg);
}
});
}
});

回答2:

具有天赋76他