.htaccess 1.3 KB

12345678910111213141516171819202122232425262728293031
  1. <IfModule mod_expires.c>
  2. ExpiresActive On
  3. ExpiresByType image/jpeg "access plus 1 year"
  4. ExpiresByType image/gif "access plus 1 year"
  5. ExpiresByType image/png "access plus 1 year"
  6. ExpiresByType image/webp "access plus 1 year"
  7. ExpiresByType image/svg+xml "access plus 1 year"
  8. ExpiresByType image/x-icon "access plus 1 year"
  9. ExpiresByType font/ttf "access plus 1 year"
  10. ExpiresByType font/otf "access plus 1 year"
  11. ExpiresByType font/woff "access plus 1 year"
  12. ExpiresByType font/woff2 "access plus 1 year"
  13. ExpiresByType image/svg+xml "access plus 1 year"
  14. ExpiresByType video/mp4 "access plus 1 year"
  15. ExpiresByType video/mpeg "access plus 1 year"
  16. ExpiresByType application/pdf "access plus 1 year"
  17. ExpiresByType text/javascript "access plus 1 month"
  18. ExpiresByType application/javascript "access plus 1 month"
  19. ExpiresByType text/css "access plus 1 week"
  20. </IfModule>
  21. <ifModule mod_headers.c>
  22. <filesMatch ".(gif|ico|jpg|jpeg|mp4|mpeg|png|svg|webp|ttf|otf|woff|woff2)$">
  23. Header set Cache-Control "max-age=31536000, public"
  24. </filesMatch>
  25. <filesMatch ".(js|pdf)$">
  26. Header set Cache-Control "max-age=2592000, public"
  27. </filesMatch>
  28. <filesMatch ".(css)$">
  29. Header set Cache-Control "max-age=604800, public"
  30. </filesMatch>
  31. </ifModule>