ajax提交的时候出现以下错误提示 :
A cookie associated with a cross-site resource at http://houtai.aa.cn/ was set without the SameSite
attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with SameSite=None
and Secure
. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032. at login.html?:0
百度了下翻译为:与位于的跨站点资源关联的cookiehttp://houtai.aa.cn/未设置“SameSite”属性。Chrome的未来版本将只提供带有跨站点请求的cookie,前提是它们设置为“SameSite=None”和“Secure”。您可以在“开发人员工具”中的“应用程序”>“存储”>“cookies”下查看Cookie,并在中查看更多详细信息https://www.chromestatus.com/feature/5088147346030592以及https://www.chromestatus.com/feature/5633521622188032。在登录.html?:0
后端设置了以下请求头也无解
header("Access-Control-Allow-Origin: *");
header("Access-Control-Allow-Methods: GET, POST");
header("Access-Control-Allow-Headers: Origin, No-Cache, X-Requested-With, If-Modified-Since, Pragma, Last-Modified, Cache-Control, Expires, Content-Type, X-E4M-With");
请问如何解决
0 个回复