Execute a function when both ajax requests are complete. From http://api.jquery.com/jQuery.when/