jquery multiple ajax check for all done? (order not important)

Posted by second on Stack Overflow See other posts from Stack Overflow or by second
Published on 2010-01-28T10:16:39Z Indexed on 2010/05/15 9:54 UTC
Read the original article Hit count: 371

Filed under:
|
|

Is there a neat way to make sure a bunch of ajax callbacks have all finished? They don't need to be executed in order, i just need all the data to be there.

one idea is to have them all increment a counter on completion and check if counter == countMax, but that seems ugly. Also, are there sync issues? (from simultaneous read/write to the counter)

© Stack Overflow or respective owner

Related posts about jQuery

Related posts about AJAX