Skip to content

Commit

Permalink
Fixes matomo-org#5398 use Apache AddHandler only when mod_mime module…
Browse files Browse the repository at this point in the history
… is enabled. This may create situations where it's hard to debug what the problem is when mod_mime is not activated... maybe should be added to system check
  • Loading branch information
mattab committed Dec 1, 2014
1 parent fb26f67 commit e3139a3
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions plugins/Installation/ServerFilesGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,11 @@ public static function createHtAccessFiles()
"</Files>\n";

$allowStaticAssets =
"# Serve HTML files as text/html mime type\n" .
"AddHandler text/html .html\n" .
"AddHandler text/html .htm\n\n" .
"# Serve HTML files as text/html mime type - Note: requires mod_mime apache module!\n" .
"<IfModule mod_mime.c>\n" .
" AddHandler text/html .html\n" .
" AddHandler text/html .htm\n" .
"</IfModule>\n\n" .

"# Allow to serve static files which are safe\n" .
"<Files ~ \"\\.(gif|ico|jpg|png|svg|js|css|htm|html|swf|mp3|mp4|wav|ogg|avi)$\">\n" .
Expand Down

0 comments on commit e3139a3

Please sign in to comment.