How can I detect 'any' ajax request being completed using jQuery?
Posted
by Brian Scott
on Stack Overflow
See other posts from Stack Overflow
or by Brian Scott
Published on 2010-05-26T10:27:01Z
Indexed on
2010/05/26
10:31 UTC
Read the original article
Hit count: 267
I have a page where I can insert some javascript / jquery to manipulate the output. I don't have any other control over the page markup etc.
I need to add an extra element via jquery after each present on the page. The issue is that the elements are generated via an asynchronous call on the existing page which occurs after $(document).ready is complete.
Essentially, I need a way of calling my jquery after the page has loaded and the subsequent ajax calls have completed. Is there a way to detect the completion of any ajax call on the page and then call my own custom function to insert the additional elements after the newly created s ?
© Stack Overflow or respective owner