• Resolved Felipe Almeida

    (@felipealmeidacosta)


    Recently I get notice that the option “Never cache the following pages:” option from Page Cache is not working properly with regular expression entry.

    My site has the following URL structure for custom post type “Especialidades”:

    Archive

    • /especialidades/ for archive of custom post and must NOT be cached
    • /especialidades/localidade/fortaleza/ for archive of custom post with taxonomy filter, where localidade (location) is the taxonomy and fortaleza (a city name) is the term and must be cached

    Single

    • /especialidades/cardiologia/ for custom post page of post “cardiologia” and must NOT be cached
    • /especialidades/cardiologia/fortaleza/ for the same post page but an term parameter that change some information in the page and must be cached

    I have enabled Page Cache option in the General Settings and set the following regex rules in the textarea of “Never cache the following pages” in Page Cache page option:

    ^/especialidades/?$
    ^/especialidades/([\w-_]+)/?$

    At first, it works. After cleared the cache, I have tested many times in the anonymous tab, but after a while, the page that not must be cached get cached.

Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘PageCache “Never cache the following pages” not working’ is closed to new replies.