Problem: My async ajax call is stalling links on the page (but only links targeting the same domain) until the ajax has completed. To confirm this I've added a sleep(10) into the php file the ajax is referring to, so the ajax call takes at least 10 seconds to complete.
After 10 seconds the chrome console reports
XHR finished loading
and the link is then activated.
However, (and this is where it's weird) links targeting other domains are activated immediately - the ajax is terminated instantly on click and the chrome console is reporting:
XHR failed loading
and the link is activated.
How can I insure local links are treated as the remote links are - immediate.
Here is the ajax call:
$.ajax({
async:true,
url: "/ajax/ajax-get-static-calendar",
type: "GET",
data: "cid=" + $('#sm-calendar').attr('data-cid')+ "&numDays=" + $('#sm-calendar').attr('data-numdays'),
success: function(msg) {
console.log('ajax done');
}
});