AJAX a.php -> b.php -> c.php
var xhr = new XMLHttpRequest();
xhr.open('GET', 'a.php', true);
xhr.onreadystatechange(function() {
if(http.readyState == 4 && http.status == 200) {
xhr.open('GET', 'b.php', true);
xhr.onreadystatechange(function() {
if(http.readyState == 4 && http.status == 200) {
xhr.open('GET', 'c.php', true);
xhr.onreadystatechange(function() {
if(http.readyState == 4 && http.status == 200) {
// ...
}
}
xhr.send();
}
}
xhr.send();
}
});
xhr.send();