IE下跨域出现No Transport

javascript$.ajax({
        url: 'http://example.php',
        type: 'get',
        data: {},
        success: function(res) {

        }, 
        error:function(XMLHttpRequest, txtStatus, errorThrown){
          console.log(XMLHttpRequest, txtStatus, errorThrown);
        }
    });
//加了$.Support.Cors = true后提示readyState: 0, status: 0, statusText: "Error: 拒绝访问...

//改为jsonp就ok了?
$.ajax({
        url: 'http://example.php',
        type: 'get',
        data: {},
        dataType:"jsonp",
        jsonp:'callback',
        success: function(res) {

        }
    });
阅读 13.6k
1 个回答
推荐问题
宣传栏