[Plugin: W3 Total Cache] Do not process 404 errors for static objects with Word
-
The Do not process 404 errors for static objects with WordPress Setting in the Browser Cache Settings section (shown here) caused some issues for us and I recommend perhaps putting a label on for others. We use the Custom Permalink plugin By Michael Tyson. We append .html to the end of urls. .html is one of the content types that W3 is considering static content.
See Code:
# BEGIN W3TC Skip 404 error handling by WordPress for static files <IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{REQUEST_URI} !(robots\.txt|sitemap\.xml(\.gz)?) RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} \.(css|js|html|htm|rtf|rtx|svg|svgz|txt|xsd|xsl|xml|asf|asx|wax|wmv|wmx|avi|bmp|class|divx|doc|docx|exe|gif|gz|gzip|ico|jpg|jpeg|jpe|mdb|mid|midi|mov|qt|mp3|m4a|mp4|m4v|mpeg|mpg|mpe|mpp|odb|odc|odf|odg|odp|ods|odt|ogg|pdf|png|pot|pps|ppt|pptx|ra|ram|swf|tar|tif|tiff|wav|wma|wri|xla|xls|xlsx|xlt|xlw|zip)$ [NC] RewriteRule .* - [L] </IfModule> # END W3TC Skip 404 error handling by WordPress for static files
Since it is considered static content it is causing WP to tell the webserver to handle the page and the webserver is passing a 404 error in the header even though the page displays in the browser. I tested this on 2 sites (debian and suphp) and had the same issue. We noticed this because Google was throwing not found errors when crawling.
JR
- The topic ‘[Plugin: W3 Total Cache] Do not process 404 errors for static objects with Word’ is closed to new replies.