Tìm kiếm hỗ trợ

Tránh các lừa đảo về hỗ trợ. Chúng tôi sẽ không bao giờ yêu cầu bạn gọi hoặc nhắn tin đến số điện thoại hoặc chia sẻ thông tin cá nhân. Vui lòng báo cáo hoạt động đáng ngờ bằng cách sử dụng tùy chọn "Báo cáo lạm dụng".

Learn More

Why do cookies persist after clicking "Clear Data"?

  • 5 trả lời
  • 0 gặp vấn đề này
  • 22 lượt xem
  • Trả lời mới nhất được viết bởi cor-el

more options

Hi Mozilla community,

The Developer Tools -> Storage -> Cookies pane shows cookies currently being stored by Firefox.

If I close my browser, these cookies are automatically deleted. However, if I follow the steps on [1], the cookies are still there, and don't get deleted. *Why?*

Thanks in advance!

Steps to reproduce:

- Start a new Firefox session
- Open Developer Tools -> Storage -> Cookies and see that the list is empty
- Go to youtube.com and click Accept All on the cookies popup
- Developer Tools -> Storage -> Cookies now shows a cookie from YouTube, as per the attached screenshot
- Go to Settings->Privacy & Security->Cookies and Site Data -> Clear Data -> Clear
- Go back to Developer Tools -> Storage -> Cookies and click on the refresh icon
- The YouTube cookie is still there
- However either of the following actions will correctly delete this cookie:

1) closing firefox (with Always Use Private Browsing Mode enabled) 2) manually deleting the cookie from the list in Developer Tools -> Storage -> Cookies


[1] https://support.mozilla.org/en-US/kb/clear-cookies-and-site-data-firefox

Hi Mozilla community, The Developer Tools -> Storage -> Cookies pane shows cookies currently being stored by Firefox. If I close my browser, these cookies are automatically deleted. However, if I follow the steps on [1], the cookies are still there, and don't get deleted. *Why?* Thanks in advance! Steps to reproduce: - Start a new Firefox session - Open Developer Tools -> Storage -> Cookies and see that the list is empty - Go to youtube.com and click Accept All on the cookies popup - Developer Tools -> Storage -> Cookies now shows a cookie from YouTube, as per the attached screenshot - Go to Settings->Privacy & Security->Cookies and Site Data -> Clear Data -> Clear - Go back to Developer Tools -> Storage -> Cookies and click on the refresh icon - The YouTube cookie is still there - However either of the following actions will correctly delete this cookie: 1) closing firefox (with Always Use Private Browsing Mode enabled) 2) manually deleting the cookie from the list in Developer Tools -> Storage -> Cookies [1] https://support.mozilla.org/en-US/kb/clear-cookies-and-site-data-firefox
Đính kèm ảnh chụp màn hình

Giải pháp được chọn

If you are in permanent Private Browsing mode (Always use Private Browsing mode; Never Remember History) then all session data is stored in memory and purged automatically when you close Firefox, so there is no need to use "Clear history when Firefox closes" and it doesn't have effect. What you see in "Cookies and Site Data -> "Manage Data" is data from the regular session and you can only clear this data in regular mode (i.e. you need to exit PB mode).

Đọc câu trả lời này trong ngữ cảnh 👍 2

Tất cả các câu trả lời (5)

more options

All Browser will load their needed cache if you clear the Browser cache/history. It rebuilds it to access and load the needed files to run. You can't clear it completely, it will load cache to access sites.

Hữu ích?

more options

Hi Dropa, thanks very much for the reply.

If I understand correctly, you're saying that the Clear Data button doesn't delete the cookies for websites which are currently being used by Firefox. So if I'm on YouTube and click Clear Data, it doesn't delete the cookie for YouTube. Is that right?

I can delete the cookie while on YouTube by removing it via Developer Tools -> Storage -> Cookies.

So I'm trying to understand why, if the cookie can be deleted from the Developer Tools pane, the Clear Data button doesn't do the same thing. It feels like either I've misunderstood something about how cookies work, or the Clear Data button isn't very well documented, because it doesn't actually clear all the data.

Hữu ích?

more options

Giải pháp được chọn

If you are in permanent Private Browsing mode (Always use Private Browsing mode; Never Remember History) then all session data is stored in memory and purged automatically when you close Firefox, so there is no need to use "Clear history when Firefox closes" and it doesn't have effect. What you see in "Cookies and Site Data -> "Manage Data" is data from the regular session and you can only clear this data in regular mode (i.e. you need to exit PB mode).

Hữu ích?

more options

Hi cor-el (or is that Clark?!)

Thanks for picking this up and yes this has answered the question.

In case this helps anyone in the future, I will just clarify a little.

It's not the "Clear history when Firefox closes" setting that I'm asking about. Rather, I was confused about why the "Clear Data" button, which refers to cookies, not history, doesn't delete the cookies.

However, cor-el's explanation applies equally to the Clear Data button: When permanent Private Browsing mode is switched off, this button deletes the cookies as expected.

The reason is that the Clear Data button deletes cookies stored on disk. In Private Browsing mode, cookies are held in memory. So the button appears to work, but doesn't actually do anything about the in-memory data.

One of the Firefox devs has clearly thought about this issue and put a little notification in Privacy->Cookies & Site Data explaining that the "Clear history when Firefox closes" setting isn't needed in Private Browsing mode. But the the Clear Data button remains enabled, suggesting that it still works even in Private Browsing mode.

One final note: although, with Private Browsing disabled, the cookies are deleted by the Clear Data button, they are still listed in Developer Tools -> Storage -> Cookies as if they were still there, even after refreshing that pane. That behaviour seems a bit iffy to me, but perhaps there's a reason.

Thanks again cor-el and Dropa for your help!

Hữu ích?

more options

I think that you should still be able to clear the cookies and other site data kept in memory in current releases, but you won't see this in "Manage Data". I think that the Storage Inspector should reflect this in a better way.

Hữu ích?

Đặt một câu hỏi

Bạn phải đăng nhập vào tài khoản của bạn để trả lời bài viết. Vui lòng bắt đầu một câu hỏi mới, nếu bạn chưa có tài khoản.