Some Assests Are Bypassing cache
-
why some assets are bypassing cache.
The page I need help with: [log in to see the link]
-
Hi,
Cause for these static files you havecache-controlheader set asprivate. Screenshot: https://i.imgur.com/bODKKqw.jpegso how to fix it ? can you help me out to fix it !
You need to check if you have so me server rule or plugin added to your site that is adding that
cache-controlrule and remove that. Then inside this plugin settings under the cache tab, enable the option to add proper cache control header for static files. It is the last option under the cache tab.You can add the following code near the top of your.htaccessfile: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17## EXPIRES HEADER CACHING ##<IfModule mod_expires.c>ExpiresActive OnExpiresByType image/jpg "access 1 year"ExpiresByType image/jpeg "access 1 year"ExpiresByType image/gif "access 1 year"ExpiresByType image/png "access 1 year"ExpiresByType image/svg "access 1 year"ExpiresByType text/css "access 1 month"ExpiresByType application/pdf "access 1 month"ExpiresByType application/javascript "access 1 month"ExpiresByType application/x-javascript "access 1 month"ExpiresByType application/x-shockwave-flash "access 1 month"ExpiresByType image/x-icon "access 1 year"ExpiresDefault "access 3 days"</IfModule>## EXPIRES HEADER CACHING ##can i add this code in .htaccess file ?That code is not needed, when you enable the option inside the plugin settings to add proper cache control header for static file, it will add the header for the static files
in which plugin ? super cache plugin ?
This option: https://i.imgur.com/YXxyo6q.jpeg inside this plugin
it’s enable now.. can you check it’s enable now or not
No, it’s not fixed. I now see that the plugin has added it’s cache control header but the itial one is still present. You need to find from where it is being added and remove that: https://i.imgur.com/OVaTNEr.jpeg
So confused now which plugin have problem 😕…
list of plugins
akismat
jetpack
redirection
perfmatter
your plugin
yoast
shortpixel ai
Try disbling shortpixel and then jetpack to see if this persist. If so, consider contacting your host to find out from where it is being added.
issue found in converter media plugin. now its disabled can you check now its fixed or not.
Yes your static files are now being cached properly by Cloudflare: https://i.imgur.com/pF67KM3.jpeg
thank you so much for your kind help. ❤️
Happy to hear the problem has been resolved.
The topic ‘Some Assests Are Bypassing cache’ is closed to new replies.