User Tools

Site Tools


https_ssl_tls

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
https_ssl_tls [2016/05/20 17:00]
admin
https_ssl_tls [2016/05/21 11:20] (current)
admin
Line 12: Line 12:
 RewriteRule ^/?(.*) https://​yoursite.com/​$1 [R,​L]</​code>​ RewriteRule ^/?(.*) https://​yoursite.com/​$1 [R,​L]</​code>​
 This forces the HTTPS protocol to be used when visitors try to use http, and if they also type in www.yoursite.com,​ they will also end up at https://​yoursite.com This forces the HTTPS protocol to be used when visitors try to use http, and if they also type in www.yoursite.com,​ they will also end up at https://​yoursite.com
 +
 +**IMPORTANT** - make sure that the baseurl in your defines and .htaccess files are consistent with or without the WWW prefix. ​
 +>><​code>​https://​yoursite.com</​code>​
 +**OR**
 +>><​code>​https://​www.yoursite.com</​code>​
 +
  
 **NOTE** - if you happen to be using code in your .htaccess to force the WWW prefix in your URL, such as: **NOTE** - if you happen to be using code in your .htaccess to force the WWW prefix in your URL, such as:
Line 17: Line 23:
 RewriteCond %{HTTP_HOST} ^yoursite.com [NC] RewriteCond %{HTTP_HOST} ^yoursite.com [NC]
 RewriteRule ^(.*)$ http://​www.yoursite.com/​$1 [R=301,​L]</​code>​ RewriteRule ^(.*)$ http://​www.yoursite.com/​$1 [R=301,​L]</​code>​
-You should ​probably ​remove it as having 2 different URL rewrites ​could potentially ​conflict with each other.+You should remove it as having 2 different URL rewrites ​will conflict with each other.
  
  
 For more info also see: [[the_.htaccess_file|The .htaccess File]] For more info also see: [[the_.htaccess_file|The .htaccess File]]
https_ssl_tls.txt ยท Last modified: 2016/05/21 11:20 by admin