Although it seems like many people seem to be having problems with this in Stack Overflow, I can still see a description of why this is happening incorrectly ( 1 , 2 , 3 )
My code (for testing purposes):
jQuery.getScript("res/fader.js", function () { alert("loaded"); });
works flawlessly in Chrome (16). In Firefox (11), the firebug console shows the requested script and the expected response (including application mimetype / javascript). But no warnings. There is no mistake. Nothing.
If you subsequently try to refer to something in the script that was supposed to be loaded, it is still undefined (this is a few seconds after the onload event and after the console indicates that the script was found).
Update
I am using jQuery 1.9.1
source share