Created
March 14, 2019 20:09
-
-
Save joemaller/0d7b513f3abea0f8dcd9938963be9cb8 to your computer and use it in GitHub Desktop.
A very simple htaccess file for redirecting traffic from http to https (insecure to secure)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RewriteEngine On | |
RewriteCond %{ENV:HTTPS} !on | |
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] | |
ErrorDocument 404 /404.html | |
ErrorDocument 401 "Unauthorized Access" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment