Normally when I use the XMLHttpRequest object to perform a 'get' with javascript I use something like the following to check the response:
Code: Select all
if (objXML.readyState === 4) { //complete?
if (objXML.status === 200) {
//do something
} else if (objXML.status > 200) {
//retry
}
}
In the past XMLHttpRequest.status has always returned an integer/number
Status1.JPG
but I a now seeing a problem where the .status seems to be an error object!
Status2.JPG
which of course messes up the above code - it creates an exception on the first test of status as I am performing a strict comparison.
As a work around I will change to loose comparison, but I cannot find any reference to this via Google. Anyone else seen it before?
You do not have the required permissions to view the files attached to this post.