WJ___ WJ___ - 1 month ago 18
jQuery Question

jQuery.getJSON() doesn't work properly in IE9 and below

var video_id='VA770wpLX-Q';

$.getJSON('http://gdata.youtube.com/feeds/api/videos/'+video_id+'?v=2&alt=jsonc',function(data,status,xhr){
alert(data.data.title);
});


I am having issue in using getJSON() in ie9 and below, the request is done but function is not running, it is working on all the other browsers except IE, already tested over different jquery versions still no luck, help!

Answer

After hours googling and I found a simple and effective solution!

jQuery.getJSON not working properly in IE8 with gdata json-c. Why?

Just add &callback=? to the end of your url string.

Comments