jQuery $.when() and $.done() are exactly what you need:
$.when($.ajax("/page1.php"), $.ajax("/page2.php"))
.then(myFunc, myFailure);
More Related Contents:
- How to make page loaders/animations/transitions
- How to manage a redirect request after a jQuery Ajax call
- Make cross-domain ajax JSONP request with jQuery
- Access Control Request Headers, is added to header in AJAX request with jQuery
- jQuery XML error ‘ No ‘Access-Control-Allow-Origin’ header is present on the requested resource.’
- JavaScript/jQuery to download file via POST with JSON data
- Load More Posts Ajax Button in WordPress
- URL Encode a string in jQuery for an AJAX request
- Download pdf file using jquery ajax
- “Mixed content blocked” when running an HTTP AJAX operation in an HTTPS page
- jQuery .load() / .ajax() not executing javascript in returned HTML after appended
- How to refresh page on back button click?
- jQuery Ajax requests are getting cancelled without being sent
- jQuery iframe load() event?
- Send FormData and String Data Together Through JQuery AJAX?
- Ajax success event not working
- syntax error: unexpected token
- How to disable beforeunload action when user is submitting a form?
- jquery ajax readystate 0 responsetext status 0 statustext error
- how to assign javascript variable value to php variable
- Jquery Ajax prevent fail in a deferred sequential loop
- Jquery getJSON populate select menu question
- Why my $.ajax showing “preflight is invalid redirect error”?
- How can I get all a form’s values that would be submitted without submitting [duplicate]
- jQuery 3 slim ajax basic example
- Bind events on dynamic created elements inserted by AJAX (check box)
- Jquery Ajax beforeSend and success,error & complete
- How to upload string as file with jQuery or other js framework
- Set Request Header jQuery Ajax
- ‘append’ called on an object that does not implement interface FormData