ho alcune chiamate Ajax nel mio document.ready()jquery: attendere che tutte le chiamate Ajax finiscono poi continuare
come:
for (j=1; j <= 7; j++){
(function(index) {
$.getJSON('my.php', {id:index},
function(data) {
$.each(data, function(index2, array){
........
});
});
})(j)
}
//DO NOT CONTINUE UNTIL FINISH AJAX CALLS
........
MORE JQUERY CODE
Come posso forzarlo ad aspettare e non continuare fino a quando abbiamo ricevere tutte le richiamate dalle richieste Ajax?
vedere la mia altra risposta qui: http://stackoverflow.com/a/11315571/49885, ajaxStop è ciò che si vuole, il suo stato costruito in fin jQuery 1.0 –