I have the following jquery ajax code that is working in ALL other browsers except Safari 4 and Safari 5 in Mac. It works correctly in Safari 6.
$.ajax({
type : "POST",
url : crossDomainURL,
contentType : "text/plain",
data : requestData,
dataType : "text",
success : function(e) {
console.log("success");
},
error : function(e) {
console.dir(e);
console.log("FAILLLLLLLLL");
},
});
It prints the "FAILLLLLLL" statement on the console everytime with a statusText of error and status of 0. The server at crossDomainURL is correctly configured to handle this type of request (and thus it works correctly in all other browsers).
But in case of Safari (4 and 5) on a Mac, the ajax call does not even leave the browser. It seems related to CORS issue, but I am confused as to why this same code works in Firefox and Chrome and Safari 6 correctly but not in Safari 4 & 5.
I appreciate any ideas.
Thanks.
EDIT: Older versions of Safari can be found here: http://michelf.ca/projects/multi-safari/