admin管理员组文章数量:1396739
I am working on a live ticker which works fine but when I am reloading the page I am running into this error:
XMLHttpRequest cannot load /ajax/ajax-liveticker.php due to access control checks.
Is there anything I can do to prevent this? I am pretty new to ajax.
setInterval(function () {
$.ajax({
processData: false,
contentType: false,
data: ajaxSendData,
dataType: "json",
error: function (xhr, ajaxOptions, thrownError) {
console.log(xhr.status);
console.log(thrownError);
},
type: "POST",
url: "ajax/ajax-liveticker.php"
}).done(function (data) {
$("#liveticker").html(data.html)
});
}, 5000);
本文标签: jqueryXMLHttpRequest cannot load due to access control checks when reloading the pageStack Overflow
版权声明:本文标题:jquery - XMLHttpRequest cannot load due to access control checks when reloading the page - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744145559a2592818.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论