I'm trying to access a script as JSON via AJAX, which works fine on Safari and other browsers but unfortunately will not execute in Chrome. It's coming with the following error:
拒绝从"*"执行脚本,因为其MIME类型("应用程序/json")不可执行,并且启用了严格的MIME类型判断.
以下是请求:
$.ajax({
url: "http://some_url/test.json?callback=?",
type: "GET",
dataType: 'json',
cache: true,
success: function (data, status, error) {
console.log('success', data);
},
error: function (data, status, error) {
console.log('error', data, status, error);
}
});
有人有解决办法吗?