I am loading an AJAX request of another HTML page, which is then inserted into the DOM element of the current page.
The page that I get through AJAX includes linklinks to stylesheets, as well as several images that need to be downloaded from the server.
I want to execute the code after all resources from the AJAX call are loaded , including reference stylesheets and images.
Please note: these stylesheets and images are not directly loaded from AJAX, but loaded as a result of inserting HTML from an AJAX call.
So I'm not looking for a callback success:, but rather like the other $(window).load(function () { ... });after calling AJAX (I tried listening again $(window).load).
Let me know if you need more code.
source
share