Replies: 0
Hi,
I use the Page Cache and Browser Cache with nginx.
I’m satified with the base value of the Browser Cache for HTML pages, but for some specific pages I want the caching time to be far lower .
But I could not successfully change the expire time of the specific page.
I have added in the top of my nginx configuration file :
location ^~ /my-specific-page/ {
expires 60s;
etag on;
if_modified_since exact;
add_header Pragma "public";
add_header Cache-Control "public";
try_files $uri $uri/ /index.php?$args;
}
but with no success.
I put it juste before the Page Cache block :
# BEGIN W3TC Page Cache cache
location ~ /app/cache/page_enhanced.*gzip$ {
[...]
}
How can I modify the expire time of specific pages ?
By slug of post id, whatever for me.