.htaccess being ignored
-
Hi,
I had the plugin working just fine on a shared hosting. I recently migrated everything to a VPS. After setting everything up, look like the .htaccess is being ignored by cloudfare. However the plugin does write on .htaccess.
This is the code which was working before the migration
# BEGIN WP Cloudflare Super Page Cache # The directives (lines) between "BEGIN WP Cloudflare Super Page Cache" and "END WP Cloudflare Super Page Cache" are # dynamically generated, and should only be modified via WordPress filters. # Any changes to the directives between these markers will be overwritten. <IfModule mod_expires.c> ExpiresActive on ExpiresByType application/xml "access plus 0 seconds" ExpiresByType text/xsl "access plus 0 seconds" </IfModule> <FilesMatch "\.(xml|xsl)$"> <IfModule mod_headers.c> Header set Cache-Control "no-cache, no-store, must-revalidate, max-age=0" </IfModule> </FilesMatch> <FilesMatch "robots\.txt"> <IfModule mod_headers.c> Header set Cache-Control "no-cache, no-store, must-revalidate, max-age=0" </IfModule> </FilesMatch> <FilesMatch "\.(css|js|pdf)$"> <IfModule mod_headers.c> Header set Cache-Control "public, must-revalidate, proxy-revalidate, immutable, max-age=2592000, stale-while-revalidate=86400, stale-if-error=604800" </IfModule> </FilesMatch> <FilesMatch "\.(jpg|jpeg|png|gif|ico|eot|swf|svg|webp|avif|ttf|otf|woff|woff2|ogg|mpeg|avi|mkv|webm|mp3)$"> <IfModule mod_headers.c> Header set Cache-Control "public, must-revalidate, proxy-revalidate, immutable, max-age=31536000, stale-while-revalidate=86400, stale-if-error=604800" </IfModule> </FilesMatch> <IfModule mod_rewrite.c> RewriteCond %{REQUEST_URI} ^(.*)?/wp-content/wp-cloudflare-super-page-cache/exposedtostrangers.com/debug.log(.*)$ RewriteRule ^(.*)$ - [F] </IfModule> <FilesMatch "wp-cron.php"> <IfModule mod_headers.c> Header set Cache-Control "no-cache, no-store, must-revalidate, max-age=0" </IfModule> </FilesMatch> # Added to bypass mp4 files from Cloudfare's Cache. <FilesMatch "\.(mp4)$"> <IfModule mod_headers.c> Header set Cache-Control "no-cache, no-store, must-revalidate, max-age=0" </IfModule> </FilesMatch> # Added to cache only the latest mp4 file. Update with every release. <FilesMatch "video1\.(mp4)$"> <IfModule mod_headers.c> Header set Cache-Control "public, must-revalidate, proxy-revalidate, immutable, max-age=31536000, stale-while-revalidate=86400, stale-if-error=604800" </IfModule> </FilesMatch> # Added to cache only the latest mp4 file from GIF. Update with every release. <FilesMatch "video2\.(mp4)$"> <IfModule mod_headers.c> Header set Cache-Control "public, must-revalidate, proxy-revalidate, immutable, max-age=31536000, stale-while-revalidate=86400, stale-if-error=604800" </IfModule> </FilesMatch> # END WP Cloudflare Super Page CacheThe plugin is caching everything, despite the rules to no cache all .mp4s except 2 videos.
I can confirm that modules mod_expires and mod_headers on apache are turned on. Nginx is being used as a reverse proxy.
Any idea what could be going on?
Thanks
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
The topic ‘.htaccess being ignored’ is closed to new replies.