|
Hello, Does $.getScript() have an error callback ? In my case, i call gdata Youtube API in order to request data on a video. If the video exists, the request works fine, but it failed if video does not exists. The classic $.getScript() callback (the 2nd argument callback) is called too late, after other script calls. |
|
The $.getScript() method doesn't have an error callback function; if your problem is that you doesn't get the script, the callback function of $.getScript would never be called than you should use the $.ajax method intead as shown ahead:
Otherwise if you have errors once the callback is called (and that means the script is on the page) than you should manage the error in your callback function. |


