87,910
社区成员
发帖
与我相关
我的任务
分享
$.ajax({
type: 'GET',
async: false,
url: 'http://www.webxml.com.cn/WebServices/IpAddressSearchWebService.asmx/getCountryCityByIp?callback=?',
data:{theIpAddress:host_ip[0]},
dataType: 'jsonp',
jsonp: "callback",
success: function(msg){
alert(JSON.stringify(msg));
},
error:function(XMLHttpRequest, textStatus, errorThrown){
alert(XMLHttpRequest.status);
alert(XMLHttpRequest.readyState);
alert(XMLHttpRequest.responseText);
alert(textStatus);
alert(errorThrown);
console.log(textStatus);
}
});
$.ajax({
type: 'GET',
async: false,
url: 'http://www.webxml.com.cn/WebServices/IpAddressSearchWebService.asmx/getCountryCityByIp?callback=?',
data:{theIpAddress:host_ip[0]},
dataType: 'jsonp',
jsonp: "callback",
success: function(msg){
alert(JSON.stringify(msg));
},
error:function(XMLHttpRequest, textStatus, errorThrown){
alert(XMLHttpRequest.status);
alert(XMLHttpRequest.readyState);
alert(XMLHttpRequest.responseText);
alert(textStatus);
alert(errorThrown);
console.log(textStatus);
}
});
HttpContext.Current.Response.Write(callback + "({\"Address\":\"" + backUrl + "\"})");
HttpContext.Current.Response.End();//加这个试试
return callback + “({" + ‘“’ + ”Adderss“ + ‘”’ + ‘:’ + backUrl + ‘”’ + “})”;