jquery getScript function never fails?
问题 The jQuery getScript fail function is never called. See this fiddle: http://jsfiddle.net/getsetbro/8xNMs/ $.getScript("http://api.jquery.com/scripts/jquery.NO-SUCH-FILE.js").done(function() { console.log('yep'); }).fail(function() { console.log('fail function does not fire fine'); }); And the complete function is never called: http://jsfiddle.net/getsetbro/ns6yQ/ $.ajax({ url: url, type: 'get', crossDomain: true, dataType: 'script', async:false, cache:false, success: function(result) {