jQuery: Execute function after all ajax .load() requests are finished

Posted by Mike on Stack Overflow See other posts from Stack Overflow or by Mike
Published on 2010-03-23T19:03:36Z Indexed on 2010/03/23 19:23 UTC
Read the original article Hit count: 220

Filed under:
|

I have a page that has a tab set. Each of the tabs is loaded by the jQuery .load() function.

I want to display a loading animation that disappears when all of the ajax requests are finished. However, document.ready() has only provided me with limited success.

How can I ensure that all ajax requests are completed before executing the code to hide the loading animation?

Thanks!

© Stack Overflow or respective owner

Related posts about AJAX

Related posts about jQuery