• Resolved rcain

    (@rcain)


    Hi,

    Firstly thanks for a great plugin. Unfortunately, I’m seeing some errors in Firefox (latest version 132.0.2) – vis:

    Cookie _ga_MYTRACKINGID has been rejected for invalid domain

    • In the browser console. For all GA (& some other) cookies. Only in Firefox and only for .co.uk domains (so far as tested).

    Researching the issue it appears that Firefox is now enforcing strict SameSite/Secure policy.

    I believe what is needed are a couple of extra options in your plugin’s settings (wp-admin > Analytics Insights > Tracking Code > Advanced Settings > Cookie Customization) to add extra options for:

    • SameSite (None/Lax/Strict)
    • IsSecure (notset/Secure)

    This would then be used to construct change :

    gtag('config', 'GA_MEASUREMENT_ID');

    to:

    gtag('config', 'GA_MEASUREMENT_ID', { cookie_flags: 'SameSite=None;Secure' });

    or equivalently:

    gtag('set', {cookie_flags: 'SameSite=None;Secure'});
    gtag('config', 'GA_MEASUREMENT_ID');

    • in the header code.

    There used to be a way to set these via Google Tag Manager (Variables), but it seems no longer possible.

    This seems to be in increasingly frequent problem for many sites, many cookies (not only GA).

    Any chance you could provide a fix such as above, or some other work-around?

    Very many thanks

    Rob

    • This topic was modified 3 months, 3 weeks ago by rcain.
    • This topic was modified 3 months, 3 weeks ago by rcain.
    • This topic was modified 3 months, 3 weeks ago by rcain.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Alin Marcu

    (@deconf)

    Thank you for the detailed report.

    It will be implemented on next release.

    Thanks again!

    Thread Starter rcain

    (@rcain)

    Outstanding. Thanks Alin. Looking out for the next release ??

    Plugin Author Alin Marcu

    (@deconf)

    Fixed on 6.3.9. Only SameSite attribute was added, because beside None, the other two settings don’t require isSecure.

    If there are further questions let me know.

    Thanks again for your detailed feedback on the issue.

    • This reply was modified 3 months, 3 weeks ago by Alin Marcu.
Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.