- 🇩🇪Germany Anybody Porta Westfalica
This came up again in ✨ Hotjar and other random library cookie consent Needs work and I agree it should be implemented, at least better support that optionally.
I wrote the following in that issue:
I think the module already offers, what it needs to do that smart, with the JS callbacks. We just need to either add another optional callback on refusal, which deletes a list of cookies by their name or add a helper function that can be called in the existing callback... We can at least add that optionally. It has to be done in JS for the caching reasons.
The way COOKiES works, I'd say we should implement the cookie names in the code of the submodules, instead of individual configuration (if needed we can still add another submodule which allows attaching further cookie names to services in the UI).
So in contrast to the patches here, I think it should be code (like the library names), not configuration!
I also thought about adding a setting per service to enable / disable the cookie deletion on reject, but I don't think it's really needed, it should just be done. It will then be the job of the submodule implementations to list the cookie names to delete on reject. If none given, none will be deleted.
That all has to be done in the JS callbacks, as server-side won't work with caches.Setting the priority to major to get this up in the list of things that need to be done.
- 🇫🇷France hesslinger
Hello @Anybody,
sorry for long time without work on it issue.
Can you Close https://git.drupalcode.org/issue/cookies-3217333 ? because started branch is outdated.
To be sure to understand well you prefer kill cookie directly in a submodule (with settings form) ?
- 🇫🇷France hesslinger
Hi, Can't make fork...
I suggest the following patch : https://www.drupal.org/files/issues/2023-10-20/cookies-3217333-ga-gtag.p... →
The cookies _ga, _ga_* and _gid should be correctly removed when consent is revoked (via the cookies_ga and cookies_gtag submodules).
- Status changed to Needs review
about 1 year ago 12:53pm 20 October 2023 - 🇪🇸Spain uridrupal
After the update to Drupal10.1.6 and version Cookies 1.2.7 this patch stopped working for me. I can apply it but it does nothing when removing consent.