IE not triggering jQuery Ajax success

A simple fix of this problem is to provide the jQuery setting dataType : 'text' or dataType : 'xml' or dataType : 'json' or any other available response type.

I had same problem, but it's working fine after specifying the dataType setting in the .ajax call.

IE is really not an intelligent browser, it doesn't assume the default value string.

Try it... good luck.


Try setting the cached-option to false.

   $.ajax({        
            async: false,
            cache: false, 
            type: "get",
            url:imgsArray[img],
            success:function(imgFile){
                    alert("success");
                    //do something useful
                    },
                    error:function(XMLHttpRequest,status,error){
                    //do nothing
            }
    });//ajax

I had a similar problem -- IE appears to trigger failure if it can't parse the response as xml, even if the request was a success, so if you're requesting an image, for example, it would return a xhr.status of 200 in the error block.

I stuck my "success" functionality in the success block for FF and in the error block wrapped in an "if (xhr.status == 200)" conditional.