jQuery and AJAX response header

前端 未结 8 2403
夕颜
夕颜 2020-11-22 10:45

So I\'ve got this jQuery AJAX call, and the response comes from the server in the form of a 302 redirect. I\'d like to take this redirect and load it in an iframe, but when

相关标签:
8条回答
  • 2020-11-22 11:21

    try this:

    type: "GET",
    async: false,
    complete: function (XMLHttpRequest, textStatus) {
        var headers = XMLHttpRequest.getAllResponseHeaders();
    }
    
    0 讨论(0)
  • 2020-11-22 11:22
     var geturl;
      geturl = $.ajax({
        type: "GET",
        url: 'http://....',
        success: function () {
          alert("done!"+ geturl.getAllResponseHeaders());
        }
      });
    
    0 讨论(0)
提交回复
热议问题