pressidium / pressidium-cookie-consent

🍪 Lightweight, user-friendly and customizable cookie consent banner to help you comply with the EU GDPR cookie law and CCPA regulations.
https://wordpress.org/plugins/pressidium-cookie-consent/
GNU General Public License v2.0
48 stars 2 forks source link

Plugin keeps loading on all pages after accept #69

Open supermacservice opened 4 months ago

supermacservice commented 4 months ago

I have issues with this Wordpress plugin. It keeps reloading on every page. Anyone knows how to solve this?

I get the issue on this site: Ammetid.dk

I am also using the plugin on Applegenbrug.dk with the same settings, but no issues.

Thank you

over-engineer commented 4 months ago

Hey, @supermacservice!

I’ve checked your website (ammetid.dk) on both Firefox and Google Chrome, but I couldn’t reproduce the issue. It’s possible that a browser extension is interfering with cookie settings, or you might have to reset your browser’s cache.

Would you mind testing it on a different browser, ideally without any browser extensions installed?

Earntor commented 2 months ago

Same happens to my website. When, on the homepage you accept the cookies, and then visit this url https://www.houtvanuwvloer.nl/product-categorie/lakken/ it appears again. It happens on several pages. I also tried it on the phone, same issue. Can you please help me?

over-engineer commented 2 months ago

Hey, @Earntor!

I’ve checked your website (houtvanuwvloer.nl) on both Firefox and Google Chrome, but I couldn’t reproduce the issue.

However, I did notice the following error in the JavaScript console:

Uncaught SyntaxError: Invalid regular expression: /*.ads.google.com/i: Nothing to repeat (at block-scripts.js:1:433)

which could lead to unintended behavior for the plugin.

It looks like you entered

*.ads.google.com

as a regular expression under the “Blocked Scripts” tab, which is not valid regex.

The repeater symbol (*) matches the previous token between zero or more times. Thus, you cannot start a regular expression with a *.

You likely want something like:

.*\.ads\.google\.com

Brief explanation:

Take a look at regex101 to test and debug regular expressions.

Earntor commented 2 months ago

Thanks for your quick reply. I changed it to .*.ads.google.com, issue still remained, so I even deleted that blocker, but still same issue. I deleted the website chache and I cleared the site data in Dev Tools.

Maybe the issue lays somewhere else?

nikosgkil commented 1 month ago

Did you find the solution?

Cause I am experiencing the same issue on a wordpress installation.

Banner appears on every page, even if I Accept All cookies.

nikosgkil commented 1 month ago

Try these settings https://humbleit.dk/ Kasper Vesterbøg Ejer Humble IT ApS Ved Klosteret 12 st. 2, 2100 København Ø Denmark phone: +45 32961330 @. www.humbleit.dk www.supermacservice.dk www.nordicgear.dk www.applegenbrug.dk https://www.facebook.com/humbleit.dk … Den 27. aug. 2024 kl. 14.54 skrev nikosgkil @.>: Did you find the solution? Cause I am experiencing the same issue on a wordpress installation. Banner appears on every page, even if I Accept All cookies. — Reply to this email directly, view it on GitHub <#69 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/A5BMTI6RYH5QA2UOJFEE4C3ZTRZIVAVCNFSM6AAAAABIB3FEUGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGMJSGQ4DIOBVGU. You are receiving this because you were mentioned.

no settings are shown in your reply, can you rewrite the message please?

thanks

supermacservice commented 1 month ago
SkĂŚrmbillede 2024-08-27 kl  14 57 26 SkĂŚrmbillede 2024-08-27 kl  14 56 47
nikosgkil commented 1 month ago

Ok now I can see the images.

But even with these setttings you show on the images, the cookie box keeps on loading on every single page even if I click on accept all on its first appearence.

SkĂŚrmbillede 2024-08-27 kl 14 57 26 SkĂŚrmbillede 2024-08-27 kl 14 56 47

nikosgkil commented 1 month ago

I think I found what causes the issue. I have a multilanguage website with 6 domains, one for every language.

If I choose eg example.com as the cookie domain on the general settings tab, everything works ok for the ".com" domain. The cookie box is appearing only once and if I choose "Accept All" it does not show up again.

But if I change language from my WPML language switcher, the cookie box keeps appearing everywhere, even though at choose "Accept All" every single time.

Does someone have any ideas?

Thanks in advance!

over-engineer commented 1 month ago

Hey, @nikosgkil!

I have a multilanguage website with 6 domains, one for every language.

If I choose eg example.com as the cookie domain on the general settings tab, everything works ok for the ".com" domain.

Our plugin doesn’t support this, and it would be quite tricky to implement.

For multiple subdomains under the same domain, such as:

you could make it work by specifying your main domain (instead of a specific subdomain) in Cookie Consent → General → Cookie Domain.

However, if you’re dealing with different domains, like:

that’s not an option due to security restrictions.

We could probably work around that by leveraging the Shared Storage API, or something similar, to share the consent state across different domains. As of now, the browser compatibility is limited. It’s experimentally supported in Chromium-based browser (Chrome, Edge, Opera, etc.) — neither Firefox nor Safari support it yet.

nikosgkil commented 1 month ago

Hi @over-engineer,

thanks for the answer!

We are dealing with different domains so I guess it is not an option as you said.

Is there any chance that it can work with google tag manager?