Created
September 3, 2009 15:03
-
-
Save dtolj/180346 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
redirect to https for login pages only | |
#Redirect HTTPS to HTTP | |
Options +FollowSymlinks | |
RewriteCond %{SERVER_PORT} ^443$ | |
#select any url excluding the one containing login | |
RewriteRule (?!login\b)\b\w+\W+ http://%{HTTP_HOST}%{REQUEST_URI} [R,L] | |
#Redirect HTTP to HTTPS | |
Options +FollowSymlinks | |
RewriteCond %{HTTPS} off | |
RewriteRule ^(.*)login/$ https://%{HTTP_HOST}%{REQUEST_URI} [R,L] | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment