We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
一般 CORS 跨域的时候不允许用户携带 cookie,此时设置 Access-Control-Allow-Origin 为 * 可以允许所有域使用资源,但是如果允许携带 cookie 的话,服务端需要设置 Access-Control-Allow-Credentials 为 true,同时 Access-Control-Allow-Origin 不能设置为 *,必须设置为前端所在的确切域名。
Access-Control-Allow-Origin
*
Access-Control-Allow-Credentials
true
我记得是这样,文章写得很棒,非常感谢
The text was updated successfully, but these errors were encountered:
@Raoul1996 回头我确认一下。再增加描述,感谢!
Sorry, something went wrong.
No branches or pull requests
一般 CORS 跨域的时候不允许用户携带 cookie,此时设置
Access-Control-Allow-Origin
为*
可以允许所有域使用资源,但是如果允许携带 cookie 的话,服务端需要设置Access-Control-Allow-Credentials
为true
,同时Access-Control-Allow-Origin
不能设置为*
,必须设置为前端所在的确切域名。我记得是这样,文章写得很棒,非常感谢
The text was updated successfully, but these errors were encountered: