How to simply make the whole site HTTPS? https://drupal.stackexchange.com/questions/24072/how-to-simply-make-the-whole-site-https

If you want to redirect all of your pages to be forced to use SSL then add this to your .htaccess file.

# Redirect to HTTPS RewriteCond %{HTTPS} off RewriteCond %{HTTP:X-Forwarded-Proto} !https RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

his should be placed directly after RewriteEngine on if you have no previous rewrites.

 #Redirect without WWW
 RewriteCond %{HTTP_HOST} .
 RewriteCond %{HTTP_HOST} !^www\. [NC]
 RewriteRule ^ https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

 #Redirect to HTTPS
 RewriteCond %{HTTPS} off
 RewriteCond %{HTTP:X-Forwarded-Proto} !https
 RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] 

Then, in the settings.php: $base_url = 'https://www.yourdomainhere.com';

If you don't set up a redirect from http: to https: you may face a content duplication issue which affects SEO rankings.

To ensure you use a trusted SSL Certificate, Namecheap is offering 1-year free PositiveSSL limited to 1 cPanel primary domain for newly created account, and up to 49 new subdomains or addon domains per account. To install it, please visit the Namecheap SSL plugin.

Sign in to allow cPanel to download the list of SSL certificates you have in your account with Namecheap. You'll be able to install newly purchased certificates and install/renew already active ones.

Important: If an SSL certificate is already activated, you can install it through “Namecheap SSL” only if the domain (common name in CSR) is hosted in this cPanel. Installation of an already-active SSL will require reissue (activation from scratch).

https://www.namecheap.com/support/knowledgebase/article.aspx/9927/2218/

Why does writing to my own site give me:

You don't have permission to access /doku.php on this server.

Additionally, a 403 Forbidden error was encountered while trying to use an ErrorDocument to handle the request.

Footer

It All Starts Here -|- Brain Dumps Blog -|- Guru 42 News Portal -|- Managing Technology -|- Learning Technology -|- Contact the Guru

footerbar

Copyright | Tom Peracchio | 42 | Tech thoughts | A little bit crazy | Technology History | geek made simple

  • ssl.txt
  • Last modified: 2018/07/08 22:24
  • (external edit)