Skip to main content

Bug Tracker

Side navigation

#6241 closed bug (fixed)

Opened March 08, 2010 02:17AM UTC

Closed October 15, 2010 03:57PM UTC

Last modified March 14, 2012 02:04AM UTC

$.ajax calls the success callback in FF 3.5.8 for failed cross-origin requests.

Reported by: jambo Owned by:
Priority: undecided Milestone: 1.4.3
Component: ajax Version: 1.4.2
Keywords: Cc: jambo
Blocked by: Blocking:

In Firefox 3.5.8, when I attempt an illegal cross-origin request, the "success" callback is still called. Firefox's response to an illegal cross-origin request is now to blank xhr.responseText and set xhr.status to zero, even though xhr.readyState === 4.

This should be reproducable by simply attempting a cross-origin request to a domain that does not support it, for example with the following code:


url : "",

success : function() {

alert( "Oops!" );



Attachments (0)
Change History (4)

Changed March 08, 2010 09:21PM UTC by maqdev comment:1

The same with: Google Chrome 5, Safari 4.0.4 (Win)

Also this problem is reproduced not only for cross-origin request, but when server is down and closes connection without any HTTP status response (in last case reproduced with IE8 too).

Changed March 09, 2010 07:47PM UTC by maqdev comment:2

Here is similar problem and a fix that could help:

Changed October 07, 2010 03:46PM UTC by curiousdannii comment:3

Can be closed as #6060 has been fixed.

Changed October 15, 2010 03:57PM UTC by addyosmani comment:4

priority: → undecided
resolution: → fixed
status: newclosed

Closing as we've fixed this.