Examine the following code.
function getData() { var url = "ajaxdata/citStudents.txt"; var request = new XMLHttpRequest(); request.open("GET", url); request.onreadystatechange = function() { if (request.readyState == 4 && request.status == 200) { alert(request.responseText); } }; request.send(null);}
What does it mean if the condition (request.readyState == 4 && request.status == 200) evaluates as true?
it means there were no http errors and that the data has been returned to the browser.
it means there were was an HTTP error and that the data will not be returned to the browser.
it means the request has been sent and data will be back in 200 milliseconds or less.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here