[Plugin: WP Super Cache] new htaccess rules result in garbage sent to client
-
I just upgraded to supercache v0.8 and updated my htaccess file to match the rewrite rules specified on the supercache settings page:
# BEGIN WPSuperCache <IfModule mod_rewrite.c> RewriteEngine On RewriteBase /wordpress/ AddDefaultCharset UTF-8 RewriteCond %{REQUEST_URI} !^.*[^/]$ RewriteCond %{REQUEST_URI} !^.*//.*$ RewriteCond %{REQUEST_METHOD} !=POST RewriteCond %{QUERY_STRING} !.*=.* RewriteCond %{HTTP:Cookie} !^.*(comment_author_|wordpress|wp-postpass_).*$ RewriteCond %{HTTP:Accept-Encoding} gzip RewriteCond %{DOCUMENT_ROOT}/wordpress/wp-content/cache/supercache/%{HTTP_HOST}/wordpress/$1/index.html.gz -f RewriteRule ^(.*) /wordpress/wp-content/cache/supercache/%{HTTP_HOST}/wordpress/$1/index.html.gz [L] RewriteCond %{REQUEST_URI} !^.*[^/]$ RewriteCond %{REQUEST_URI} !^.*//.*$ RewriteCond %{REQUEST_METHOD} !=POST RewriteCond %{QUERY_STRING} !.*=.* RewriteCond %{HTTP:Cookie} !^.*(comment_author_|wordpress|wp-postpass_).*$ RewriteCond %{DOCUMENT_ROOT}/wordpress/wp-content/cache/supercache/%{HTTP_HOST}/wordpress/$1/index.html -f RewriteRule ^(.*) /wordpress/wp-content/cache/supercache/%{HTTP_HOST}/wordpress/$1/index.html [L] </IfModule> # END WPSuperCache
All dynamic pages are sent as garbage to the client. If I revert to the previous rules it doesn’t happen:
# BEGIN WPSuperCache <IfModule mod_rewrite.c> RewriteEngine On RewriteBase /wordpress/ AddDefaultCharset UTF-8 RewriteCond %{REQUEST_URI} !^.*[^/]$ RewriteCond %{REQUEST_URI} !^.*//.*$ RewriteCond %{REQUEST_METHOD} !=POST RewriteCond %{QUERY_STRING} !.*s=.* RewriteCond %{QUERY_STRING} !.*p=.* RewriteCond %{QUERY_STRING} !.*attachment_id=.* RewriteCond %{QUERY_STRING} !.*wp-subscription-manager=.* RewriteCond %{HTTP:Cookie} !^.*(comment_author_|wordpress|wp-postpass_).*$ RewriteCond %{HTTP:Accept-Encoding} gzip RewriteCond %{DOCUMENT_ROOT}/wordpress/wp-content/cache/supercache/%{HTTP_HOST}/wordpress/$1/index.html.gz -f RewriteRule ^(.*) /wordpress/wp-content/cache/supercache/%{HTTP_HOST}/wordpress/$1/index.html.gz [L] RewriteCond %{REQUEST_URI} !^.*[^/]$ RewriteCond %{REQUEST_URI} !^.*//.*$ RewriteCond %{REQUEST_METHOD} !=POST RewriteCond %{QUERY_STRING} !.*s=.* RewriteCond %{QUERY_STRING} !.*p=.* RewriteCond %{QUERY_STRING} !.*attachment_id=.* RewriteCond %{QUERY_STRING} !.*wp-subscription-manager=.* RewriteCond %{HTTP:Cookie} !^.*(comment_author_|wordpress|wp-postpass_).*$ RewriteCond %{DOCUMENT_ROOT}/wordpress/wp-content/cache/supercache/%{HTTP_HOST}/wordpress/$1/index.html -f RewriteRule ^(.*) /wordpress/wp-content/cache/supercache/%{HTTP_HOST}/wordpress/$1/index.html [L] </IfModule> # END WPSuperCache
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘[Plugin: WP Super Cache] new htaccess rules result in garbage sent to client’ is closed to new replies.