• Hello!

    I would be most grateful If you will tell me where should I add this code:

    location ~* \.(xml|xsl)$ { add_header Cache-Control “no-cache, no-store, must-revalidate, max-age=0”; expires -1; }
    location /robots.txt { add_header Cache-Control “no-cache, no-store, must-revalidate, max-age=0”; expires -1; }
    location ~* \.(css|js|pdf)$ { add_header Cache-Control “public, must-revalidate, proxy-revalidate, immutable, max-age=2592000, stale-while-revalidate=86400, stale-if-error=604800”; expires 30d; }
    location ~* \.(jpg|jpeg|png|gif|ico|eot|swf|svg|webp|avif|ttf|otf|woff|woff2|ogg|mp4|mpeg|avi|mkv|webm|mp3)$ { add_header Cache-Control “public, must-revalidate, proxy-revalidate, immutable, max-age=31536000, stale-while-revalidate=86400, stale-if-error=604800”; expires 365d; }
    location /wp-cron.php { add_header Cache-Control “no-cache, no-store, must-revalidate, max-age=0”; expires -1; }
    location = /wp-content/wp-cloudflare-super-page-cache/leasing.sos.pl/debug.log { access_log off; deny all; }

    I presume it is the config.php file but not shure that’s why I am asking for indication.

    One more thing.

    I am hosting my site on Cloudways, which use NGINX with Apache in The Perfect Combination…as they say.

    Do I have to add this code above if I am on Cloudways anyway?

    Regars,

    Greg

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Contributor iSaumya

    (@isaumya)

    Hi @gregywordpress,
    If your nase server is apache which support htaccess file, the plugin will automatically add the rules to the htaccess file you don’t need to manually add the rules to htaccess.

Viewing 1 replies (of 1 total)
  • The topic ‘Where to add the browser caching rules?’ is closed to new replies.