运维日志您现在的位置是:首页 > 博客日志 > 运维日志

Access to XMLHttpRequest at xxx from origin xxx has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the r

<a href='mailto:'>微wx笑</a>的头像微wx笑 2022-06-18运维日志 2 0关键字: XMLHttpRequest  跨域  

Access to XMLHttpRequest at xxx from origin xxx has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.

Access to XMLHttpRequest at 'https://czsc.ivu4e.com/wu2198/test.php' from origin 'https://weibo.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.VE3无知

在Chrome的开发者工具的控制台中执行ajax请求,出现跨域问题
VE3无知

image.pngVE3无知

解决方法:
VE3无知

参考:nginx php 允许跨域请求VE3无知


VE3无知

本文由 微wx笑 创作,采用 署名-非商业性使用-相同方式共享 4.0 许可协议,转载请附上原文出处链接及本声明。
原文链接:https://www.ivu4e.cn/blog/service/2022-06-18/1252.html

很赞哦! () 有话说 ()