Created
July 14, 2016 15:16
-
-
Save waako/c511a654c43180e3c90af37e5344c252 to your computer and use it in GitHub Desktop.
redirect all traffic to https, except one page, and ensure that page is served on http
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
# Force HTTPS | |
RewriteCond %{HTTPS} off | |
RewriteCond %{REQUEST_URI} !^/who-we-are/careers$ [NC] | |
RewriteRule ^(.*)$ http://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] | |
# Ensure that Careers page is not forced over HTTPS | |
RewriteCond %{HTTPS} on | |
RewriteCond %{REQUEST_URI} ^/who-we-are/careers$ [NC] | |
RewriteRule ^(.*)$ http://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Works great! 👍