I am trying to read response headers using JQuery and Ajax but not all headers are returned. Only few of them.
$(document).ready(function () {
$.ajax({
type: 'POST',
url:'http://do.convertapi.com/Word2Pdf',
data: '',
complete: function(resp){
alert(resp.getAllResponseHeaders());
}});
});
Working example: http://jsfiddle.net/tomasr/7jWSv/3/
The server response has CORS header included above, so it should be no problems accessing headers using ajax?
Access-Control-Allow-Origin:*
I would like to read all response headers using ajax, any idea how to do that?
type: "GET", async: false, complete: function (XMLHttpRequest, textStatus) { var headers = XMLHttpRequest.getAllResponseHeaders(); }