Guest User

Untitled

a guest
Dec 13th, 2017
58
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.36 KB | None | 0 0
  1. RewriteCond %{HTTP_HOST} ^www.(.*)$ [NC]
  2. RewriteRule ^(.*)$ https://%1/$1 [R=301,L]
  3.  
  4. RewriteCond %{HTTPS} !on
  5. RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
  6.  
  7. DocumentRoot /var/www/public_html
  8.  
  9. http://example.com -> https://example.com
  10. http://www.example.com -> https://example.com
  11.  
  12. https://www.example.com -> https://example.com
Add Comment
Please, Sign In to add comment