Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP


xhr.status == 0 errors in ajax calls with 10% of IE8 users in ujs 2.1.2 #279

holli opened this Issue · 0 comments

2 participants


We upgraded to newest ujs from version 1.0.19 and started getting complaints from IE8 users that our ajax buttons won't work. From the logs we were calculating that anything between 5%-15% of IE8 users had some problems. Problem was that we were not able to confirm this with our IE8 machines so we couldn't verify what's the problem.

We tested running totally same setup on the production, only ujs javascript was changed. With new ujs we had thousands of xhr.status == 0 errors in our analytics (and also some complaints from our users)...

I tried to check what would cause the problem by diffing ujs versions but I don't have any ideas:

All the problematic ajax buttons had data-disable-with info but I don't think thats the problem. Some other ajax functions might have worked allright but it's hard to confirm this from normal users. All the advanced users use some decent browsers anyway :) E.g. draganddrop migth been functional. Go figure.

This is how we log the errors. Both to google analytics and to our server.

$jq(document).ajaxError(function(e, xhr, settings) {
    _gaq.push(['_trackEvent', 'AjaxError', "xhr.status_"+xhr.status+"_first", settings.url]);
    params = { category: 'js_error.ajaxError', 'xhr.status': xhr.status }
    $"/common/log_request", params);

Only common thing in user_agent infos was MSIE 8.0. Url, button, operating system etc differed.

So basically the ajax call was newer sent to our server. It resulted in ajaxError right away with xhr.status = 0.

@ebeigarts ebeigarts referenced this issue in jquery/jquery

Fix for #11645 #751

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.