Created
May 31, 2020 00:29
-
-
Save taricco/ec6c21b92fc4c6f9847b5f44cdeb5bdd 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
| RewriteEngine On | |
| # Force WWW | |
| RewriteCond %{HTTP_HOST} ^domain.com [NC] | |
| RewriteRule ^(.*)$ https://www.domain.com/$1 [R=302,NC] | |
| # Force HTTPS/SSL | |
| RewriteCond %{HTTPS} off | |
| RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [R=302,L] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment