I have an ajax request like this:
$.ajax({
url: "/Controller/DoSomething/",
data: { status:status
},
type: "post",
dataType: "json",
success: function (XMLHttpRequest ) {
},
error: function(XMLHttpRequest, textStatus, errorThrown){
}
});
when the server goes down, I get this error on chrome's console:
POST http://localhost:#####/Controller/DoSomething/ net::ERR_CONNECTION_REFUSED
Debugging the XMLHttpRequest object I found a member statusText: "error"
the second parameter "textStatus"
: has the value "error"
the third parameter "errorThrown"
: has an empty value
the responseText
member is also empty
But I would like to get the console's error message, is there a way, or another member that has a detailed message?