Gzip setup results in 500 Internal Server Error
-
Hello,
Following your instructions to add support for .css.gz and .js.gz by adding the following lines to .htaccess …
#Serve gzip compressed CSS files if they exist and the client accepts gzip. RewriteCond %{HTTP:Accept-encoding} gzip RewriteCond %{REQUEST_FILENAME}\.gz -s RewriteRule ^(.*)\.css $1\.css\.gz [QSA] #Serve gzip compressed JS files if they exist and the client accepts gzip. RewriteCond %{HTTP:Accept-encoding} gzip RewriteCond %{REQUEST_FILENAME}\.gz -s RewriteRule ^(.*)\.js $1\.js\.gz [QSA] #Serve correct content types, and prevent mod_deflate double gzip. RewriteRule \.css\.gz$ - [T=text/css,E=no-gzip:1,E=is_gzip:1] RewriteRule \.js\.gz$ - [T=text/javascript,E=no-gzip:1,E=is_gzip:1] Header set Content-Encoding "gzip" env=is_gzip
This results in pages not being served at all with the following error …
500 Internal Server Error Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator at admin@localhost to inform them of the time this error occurred, and the actions you performed just before this error. More information about this error may be available in the server error log. Apache/2.4.41 (Ubuntu) Server Port 443
Please advise.
Oliver
Viewing 9 replies - 1 through 9 (of 9 total)
Viewing 9 replies - 1 through 9 (of 9 total)
- The topic ‘Gzip setup results in 500 Internal Server Error’ is closed to new replies.