So far, while developing web applications I have always taken one point into assumption - that it has to run on a web-server.
But when dealing with pure client-side web apps, we often overlook the fact that it should be able to be run by simply double-clicking on the homepage file (index.html).
When XMLHttpRequest'sreadyState reaches a value of 4, we further check for a response code 200 from the web-server before doing anything with the responseText / responseXML. But when running it locally - not on a webserver, the status code value will alway be 0.
0 comments:
Post a Comment