RewriteCond %{HTTP_HOST} ^((www\.)?)domain\.tld$ [NC]
RewriteCond %{HTTPS} !=on
RewriteRule ^(.*)$ https://www.domain.tld/$1 [L,R=301]
 
ssl_detection_and_conditional_redirect.txt · Last modified: 2010/03/10 00:17 (external edit)
 
Except where otherwise noted, content on this wiki is licensed under the following license:CC Attribution-Noncommercial-Share Alike 3.0 Unported
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki