Ajax (Client’s Back – End)

Ajax (Client’s Back – End)

function loadDoc() {
var xhttp = new XMLHttpRequest(); //Open OOP
xhttp.onreadystatechange = function() {// Do Something When result is return
if (this.readyState == 4 && this.status == 200) {
document.getElementById(“demo”).innerHTML = this.responseText;
}
};
xhttp.open(“GET”, “ajax_info.txt”, true);
xhttp.send();
}

 

//Ajax doing at back end as client , it can changes the front end display after the back end is done.

//http://www.w3schools.com/ajax/ajax_xmlhttprequest_onreadystatechange.asp

//readystate & status representation

Back To Top