has been blocked by CORS policy: Response to preflight request doesn‘t pass access control check
时间: 2023-08-25 13:15:57 浏览: 142
回答: "has been blocked by CORS policy: Response to preflight request doesn't pass access control check"是一个常见的跨域访问问题。它意味着在请求资源时,由于缺少'Access-Control-Allow-Origin'头部,在跨域请求的响应中被阻止。解决这个问题的方法是在响应的头部中添加'Access-Control-Allow-Origin'头部,指定允许访问的域名或通配符"*"来解决跨域访问问题。你可以参考提供的链接中的解决方案来解决这个问题。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* [has been blocked by CORS policy: Response异常问题的 解决](https://blog.csdn.net/shenxiaomo1688/article/details/125164160)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 33.333333333333336%"]
- *2* [undefined](undefined)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 33.333333333333336%"]
- *3* [浏览器预检请求返回400 has been blocked by CORS policy: Response to preflight request doesn’t pass ...](https://blog.csdn.net/weixin_53512283/article/details/123923734)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 33.333333333333336%"]
[ .reference_list ]
阅读全文