防止在Chrome Devtools中清除手动设置的Cookie [英] Prevent manually set cookie from clearing in Chrome Devtools

查看:211
本文介绍了防止在Chrome Devtools中清除手动设置的Cookie的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Chrome版本73.0.3683.75

Chrome Version 73.0.3683.75

我最近注意到,每当我在Chrome中手动设置Cookie时,要么浏览或刷新页面,然后分配的值清除Cookie并不再保留。由于某些原因,手动添加新的Cookie会自动将 N / A 分配给其 Expires / Max Age 属性,以前没有发生过Cookie的值至少会在浏览器会话期间保持不变。

I noticed recently that whenever I manually set a cookie in Chrome and I either navigate away or refresh the page, then the value I assigned to the cookie is cleared and no longer persists. For some reason, adding a new cookie manually automatically assigns N/A to its Expires / Max Age property, which didn't happen before. The cookie value would at least persist during the browser session.

我还在应用程序面板上看到我添加Cookie的行以红色突出显示,但是我有没有迹象表明是什么原因造成的。感谢您的帮助。

I also see on the application panel that the row in which I add a cookie is highlighted red, but I have no indication as what is causing this. Any help is appreciated.

推荐答案

尝试填写Expires / Max-Age字段。为我工作。

Try filling Expires/ Max-Age field. Worked for me.

这篇关于防止在Chrome Devtools中清除手动设置的Cookie的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆