• Resolved sdesign

    (@sdesign-1)


    Hi

    Can you give me some advise. I excluded the following cookies from my Complianz cookie banner plugin, as it they were causing the page to continuously refresh when using LiteSpeed Cache.

    cmplz_preferences
    cmplz_consent_status
    cmplz_choice
    cmplz_statistics-anonymous
    cmplz_statistics
    cmplz_policy_id
    cmplz_marketing
    cmplz_functional

    However, disabling these cookies causes all of my pages to not be cached, and I see this message at the end of each page.

    <!– Page uncached by LiteSpeed Cache 4.4.3 on 2021-10-18 18:21:16 –>

    Any advice on how I resolve this?

    Report Number: GOJJDJMD

    Many thanks

    Alex

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Support qtwrk

    (@qtwrk)

    Hi,

    please try remove the cookie list in setting , then add this at top of your .htaccess, save and purge all

    
    RewriteRule .* - [E=Cache-Vary:cmplz_consent_status]
    

    Best regards,

    Thread Starter sdesign

    (@sdesign-1)

    Thanks, I’ve added that and all seems to be working but I have another related query if that’s okay?

    When I am logged out and test the cache I am seeing the below:

    <!-- Page optimized by LiteSpeed Cache @2021-10-19 20:30:00 -->
    <!-- Page generated by LiteSpeed Cache 4.4.3 on 2021-10-19 20:30:00 -->

    But when I am logged in and test I am only seeing

    <!-- Page generated by LiteSpeed Cache 4.4.3 on 2021-10-19 20:32:59 -->

    Are pages for logged-in users not being optimised?

    Edit: In fact looking at the source code when logged in the css/js doesn’t;t appear to be minified/combined etc. The page is much shorter when logged out.

    Report number: VNUELLCQ

    Thanks

    Alex

    • This reply was modified 3 years, 5 months ago by sdesign.
    • This reply was modified 3 years, 5 months ago by sdesign.
    Plugin Support qtwrk

    (@qtwrk)

    Hi,

    in Page optimization -> tuning -> about bottom of page, there is an option Optimize for Guests Only to controls if optimize for login user or guest user only

    Best regards,

    Thread Starter sdesign

    (@sdesign-1)

    Thanks, that worked.

    Can I check with you something else? Is it normal to not see the code at the end of each code after I have enabled Cloudflare?

    <!– Page optimized by LiteSpeed Cache @2021-10-19 20:30:00 –>
    <!– Page generated by LiteSpeed Cache 4.4.3 on 2021-10-19 20:30:00 –>

    When I disable Cloudflare the code is shown. When I enable it the code is missing. For info, I don’t have html caching enabled on Cloudflare so it should only be caching the assets.

    Thanks

    Alex

    Plugin Support qtwrk

    (@qtwrk)

    Hi,

    did you enable “HTML minify” in CF ? HTML minify will remove this comment in HTML source code

    Best regards,

    Thread Starter sdesign

    (@sdesign-1)

    Yes I did wonder if that might be the case. Should I have the optimisation (css minify etc.) turned off in CF if I’m already optimising in Litespeed Cache (or vice Versa)?

    Plugin Support qtwrk

    (@qtwrk)

    Hi,

    yes, you should only enable minify at one place , either enable it in LSCWP , or in CF

    Thread Starter sdesign

    (@sdesign-1)

    Okay thanks, I’ll update that

    Thread Starter sdesign

    (@sdesign-1)

    Hi

    Following up on the original issue. I added the following code to my .htaccess as suggested.

    RewriteRule .* - [E=Cache-Vary:cmplz_consent_status]

    But today (about 3 days later) I have found I have the issue again where my pages keep refreshing. It clears after clearing my browser history.

    Do you think I should add any other cookies to the rule?

    Thanks

    Alex

    • This reply was modified 3 years, 5 months ago by sdesign.
    • This reply was modified 3 years, 5 months ago by sdesign.
    • This reply was modified 3 years, 5 months ago by sdesign.
    Plugin Support qtwrk

    (@qtwrk)

    emmmmm , maybe the cookie name I chose was incorrect, try test with other cookie name

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Pages uncached after excluding cookie banner cookies’ is closed to new replies.