Didn't know how else to put this.
Say I have a JavaScript method that makes some AJAX calls:
function makeAJAXCalls()
{
// who knows how long this will take
}
And I don't want the next function to execute until all the AJAX calls are complete. I also don't want to put the next function call into the success callback for the AJAX call.
Is there a way I can like chain these, so the next function doesn't get called until makeAJAXCalls()
is done everything it needs to do?