Support » Plugin: W3 Total Cache » Programmatically add cookies to cookie group

  • Resolved Michael Ott

    (@mikeyott)


    Hi,

    Is there a way to programmatically add cookies to an existing cookie group? Perhaps a function that can be used?

    While the Cookie Groups option solve the problem I have with pop-ups that are designed to set a cookie when dismissed, the ‘problem’s is that the pop-ups also have a dynamic cookie name which is often different, and it’s a bit of a pain to go and manually add it to a cookie group each time.

    Thanks in advance.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Actually, scratch that. I just realised these are written to .htaccess, and not the database as I’d initially thought.

    Instead, is this possible:

    If I know that there will be cookies that all have the same prefix, for example:

    test-cookie-foo=1
    test-cookie-bar=1
    test-cookie-cat=1

    Is there a way I can specify a cookie in the cookie group that will cater for all cookies that begin with test-cookie?

    Something like test-cookie*=1 would be great, but I know that probably won’t work.

    Plugin Support Marko Vasiljevic

    (@vmarko)

    Hello @mikeyott

    Thank you for your inquiry and I am happy to assist you with this.
    At the moment, no, but we have an issue opened in our Github repository to add the ability to use values as a regexp.
    Please make sure to track the progress of the issue regularly and feel free to add a suggestion!
    Thank you!

    Props for the feedback. That’s still quite helpful.

    Plugin Support Marko Vasiljevic

    (@vmarko)

    Hello @mikeyott

    You are most welcome!

    We would really appreciate it if you could take a minute and post a review here. This will help us to continue offering a top-notch product to users.
    Thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.