Discover Centmin Mod today
Register Now

Wordpress Cache-Enabler Plugin cache enabler

Discussion in 'Blogs & CMS usage' started by ahmed, Aug 22, 2020.

  1. ahmed

    ahmed Active Member

    350
    48
    28
    Feb 21, 2017
    Ratings:
    +61
    Local Time:
    1:45 PM
    Hi

    cache enabler is after sometimes shows scrambled webpages in css etc...

    when I clear cache problem solved...an ideas?
     
  2. eva2000

    eva2000 Administrator Staff Member

    45,201
    10,279
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +15,933
    Local Time:
    9:45 PM
    Nginx 1.19.x
    MariaDB 5.5/10.x
    What Cache Enabler settings have you enabled/disabled or configured ?

    cache-enabler-settings-220820-02.png cache-enabler-settings-220820-03.png

    Also, centmin.sh menu option 22 usually pairs Cache Enabler with Autoptimize plugin. So depending on your Wordpress theme, you may need tune Autoptimize to exclude some js/css files in your theme and/or tune Autoptimize settings

    autoptimize-settings-220820-01.png autoptimize-settings-220820-02.png autoptimize-settings-220820-03.png autoptimize-settings-220820-04.png
     
  3. ahmed

    ahmed Active Member

    350
    48
    28
    Feb 21, 2017
    Ratings:
    +61
    Local Time:
    1:45 PM
    upload_2020-8-22_12-1-1.png

    autoptomize is disabled
     
  4. ahmed

    ahmed Active Member

    350
    48
    28
    Feb 21, 2017
    Ratings:
    +61
    Local Time:
    1:45 PM
    re-enabled autoptopmize to see how it work
     
  5. eva2000

    eva2000 Administrator Staff Member

    45,201
    10,279
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +15,933
    Local Time:
    9:45 PM
    Nginx 1.19.x
    MariaDB 5.5/10.x
    if autoptimize was disabled then problem is your style itself - probably messed up style got cached
     
  6. ahmed

    ahmed Active Member

    350
    48
    28
    Feb 21, 2017
    Ratings:
    +61
    Local Time:
    1:45 PM
    The reason is that your site uses some "nonces" (WordPress Nonces « WordPress Codex).

    A nonce is a security token printed into the HTML. It's only valid for a certain length of time.

    When you have caching, the nonce expires in the background, but the code on the page is still there - referencing an invalid nonce, so then things break.

    After the cache is cleared, the code is regenerated and references a correct nonce again.

    The solution is to set your "Clear Cache Lifespan" below to 10 hours.

    ----


    this is from another caching plugin I guess it is the same concept, I made it to 2 hours and till now is ok

    any , more help into that?