Commit 3d4d0e7c authored by Jörn Friedrich Dreyer's avatar Jörn Friedrich Dreyer Committed by Thomas Müller
Browse files

Cache js, css and woff files for a week (#26591)

increases the cache duration for css and js files from 2 hours to half a year. Should they change the versionhash changes as well and a new file is fetched. Half a year should be long enough for oc updates.

Also allows caching woff files for 7 days. Currently, there is no versionhash available, but pressing F5 will also refresh the woff files.
parent 75c72672
......@@ -20,9 +20,14 @@
SetEnv modHeadersAvailable true
# Add cache control for CSS and JS files
# Let browsers cache CSS, JS files for half a year
<FilesMatch "\.(css|js)$">
Header set Cache-Control "max-age=7200, public"
Header set Cache-Control "max-age=15778463"
# Let browsers cache WOFF files for a week
<FilesMatch "\.woff$">
Header set Cache-Control "max-age=604800"
<IfModule mod_php5.c>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment