开发者

Check if there are any AJAX request alive

开发者 https://www.devze.com 2022-12-31 23:27 出处:网络
I do a lot of AJAX Requests at the same time. I ne开发者_StackOverflow社区ed to know when EVERY requests are over. How do I check that?

I do a lot of AJAX Requests at the same time. I ne开发者_StackOverflow社区ed to know when EVERY requests are over. How do I check that? Thank you!


Increment a counter with every request you issue, decrement that counter and test for zero when you get the response.

Remember that most browsers limit the number of concurrent requests that can be issued against the same server, queueing them up. It might benefit performance if you could combine some of the requests.

0

精彩评论

暂无评论...
验证码 换一张
取 消