Last active
March 29, 2018 13:59
-
-
Save axeleroy/0b4032f862ef63c8b4842f37d97c5433 to your computer and use it in GitHub Desktop.
Force HTTPS on Wordpress sites
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
Options +FollowSymLinks | |
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteBase / | |
RewriteCond %{HTTPS} !=on | |
RewriteRule ^(.*)$ https://www.domain.tld/$1 [R,L] | |
# Replace domain.tld by you own domain name ;-) | |
# BEGIN WordPress | |
[...] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment