theitd

Enforce HTTPS / SSL

Mar 28th, 2017
610
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # Enforce HTTPS and use non-www
  2. # This checks to make sure the connection is not already HTTPS
  3. RewriteCond %{SERVER_PORT}  !^443$
  4. RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]
Advertisement