JavaScript XMLHttpRequest readyState values

If this post helps you, click an ad

In JavaScript, possible readyState values after sending an XMLHttpRequest are:

0 = open has not yet been called
1 = send has not yet been called but open has been called
2 = send has been called but no response from server
3 = data is in the process of being received from the server
4 = response from server has arrived

Related articles:
JavaScript Creating XMLHttpRequest Object for Ajax
JavaScript XMLHttpRequest send Method: Send a URL in Ajax
JavaScript XMLHttpRequest Send Method: Send a URL in Ajax
JavaScript XMLHttpRequest onreadystatechange for Ajax requests

2 Responses to “JavaScript XMLHttpRequest readyState values”

  1. Creating Ajax Applications Part II « Eager to Code, Enjoy to Debug ~ Embark into Each Stage with Your Heart Says:

    [...] readyState property: http://joeyjavas.com/2007/06/07/javascript-xmlhttprequest-readystate-values [...]

  2. Hardik Says:

    hi,

    i have an problem with xmlhttprequest-responsetext property,
    i am getting the xmlhttprequest-readystate =4 and also xmlhttprequest-status=200 but i m getting the xmlhttprequest-responsetext=Block User, how it is possible to my ip address.

    if anyone have an answer plz do replay

    Thanks,

Leave a Reply