【发布时间】:2013-06-28 19:25:03
【问题描述】:
我试图通过遵循 post here 来实现 CORS。
只是当我执行 jquery 调用时它收到错误。响应文本为 '',状态文本为 'error'。
但是,查看 Fiddler 的响应是 200/OK,结果是正确的 json 格式。
这是我的 jquery 调用:
$.getJSON("http://localhost:9999/api/v1/xxxxxxxx/", function (allData) {
log.debug(allData);
}).success(function (allData) {
}).error(function (xhr, status, data) {
console.log(xhr);
console.log(data);
console.log(status);
});
这是响应的屏幕截图:
1]Firebug
我错过了什么?
【问题讨论】:
标签: asp.net asp.net-web-api cors