I am using the following code to fetch templates from my server and display them to the user:
ta.loadTemplate = function(template, $container) {
$.ajax({
url: "/templates/" + template + ".tempo",
async: false,
dataType: "text",
success: function(data, status, xhr) {
$container.empty().html(data);
},
error: function(obj, status, error) {
ta.load404('Template '+template+' not found. Error: '+status+"\n\nResponse: "+error);
}
});
};
ta.load404
displays the 404 page template and sends me an email with the error message.
This code has been working fine for a while, but suddenly in the last couple days, I've had users get stuck in an infinite loop where it is unable to load the 404 template and just keeps looping. The error I'm receiving in my email is:
NETWORK_ERR: XMLHttpRequest Exception 101
I tried researching this, but it seems this problem seems to arise when requesting a local file using the file://
protocol. However, as you can see, I am not doing that.
The server is running on JBoss. Does anybody have any ideas on why else this network error would occur? Is there any reason this problem would arise