在静态页面上用jquery ajax调用远程webservice接口,结果访问的时候都错误弹出1 提示 500 Internal Server Error
代码如下 $(function () {
$.ajax({
type: "post",
contentType: "application/json",
url: "http://webservice.webxml.com.cn/WebServices/WeatherWS.asmx/getSupportCityString",
data: "{theRegionCode:'31127' }",
dataType: "json",
cache: false,
success: function (result) {
//$("#strCount").html(result.d);
alert(2);
},
error: function (e) {
//$("#strCoun").html(e.toString());
alert(1);
}
});
})
这个 如何解决?AjaxWeb服务HTML
代码如下 $(function () {
$.ajax({
type: "post",
contentType: "application/json",
url: "http://webservice.webxml.com.cn/WebServices/WeatherWS.asmx/getSupportCityString",
data: "{theRegionCode:'31127' }",
dataType: "json",
cache: false,
success: function (result) {
//$("#strCount").html(result.d);
alert(2);
},
error: function (e) {
//$("#strCoun").html(e.toString());
alert(1);
}
});
})
这个 如何解决?AjaxWeb服务HTML
那请问个问题哈 静态页面如何调用webservice接口?
500 基本就是 后台运行时报错
type: "get",
这个不一定非用处理程序吧,其他服务也可以 webservics什么的