我解决了将dataType参数修改为 dataType:’jsonp’ 并添加 crossDomain:true 的Access-Control-
Allow-Origin错误 __
$.ajax({ url: 'https://www.googleapis.com/moderator/v1/series?key='+key, data: myData, type: 'GET', crossDomain: true, dataType: 'jsonp', success: function() { alert("Success"); }, error: function() { alert('Failed!'); }, beforeSend: setHeader});
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)