.htaccess 741 B

123456789101112131415161718
  1. # The following directives force the content-type application/octet-stream
  2. # and force browsers to display a download dialog for non-image files.
  3. # This prevents the execution of script files in the context of the website:
  4. ForceType application/octet-stream
  5. Header set Content-Disposition attachment
  6. <FilesMatch "(?i)\.(gif|jpe?g|png)$">
  7. ForceType none
  8. Header unset Content-Disposition
  9. </FilesMatch>
  10. # The following directive prevents browsers from MIME-sniffing the content-type.
  11. # This is an important complement to the ForceType directive above:
  12. Header set X-Content-Type-Options nosniff
  13. # Uncomment the following lines to prevent unauthorized download of files:
  14. #AuthName "Authorization required"
  15. #AuthType Basic
  16. #require valid-user