百度地图IP定位

 1 $.ajax({
 2             async: false,
 3             url: 'http://api.map.baidu.com/location/ip?ak=yepyDOb3PdhD52jE5P7Oyf0X&coor=bd09ll',
 4             dataType: 'jsonp',
 5             method: "GET",
 6             error: function (jqXHR, textStatus, errorThrown) {
 7             },
 8             success: function (data, textStatus, jqXHR) {
 9                 curloc = data.content.address;
10             }
11  });
View Code
原文地址:https://www.cnblogs.com/godboy1989/p/4091129.html