50
rated 0 times
[
55]
[
5]
/ answers: 1 / hits: 35095
/ 11 Years ago, thu, september 12, 2013, 12:00:00
I'm looking for a list of http status codes in Javascript. Are they defined in any implementation?
I've had a look at XMLHttpRequest
, but only found readyState
constants.
var xhr = new XMLHttpRequest();
console.log(xhr.DONE); //4
I'm looking for something like
console.log(xhr.statusCodes.OK); //200
Which obviously doesn't exist on the xhr object.
More From » javascript