Hello Moodlers,
I am trying to setup SSL on my entire Moodle site. I have bought a Comodo issued wildcard SSL certificate via my host Blue Host account.
The details of my server setup are:
Blue Host Cloud Hosting | Moodle 3.2.3 | PHP 5.6.29 | MySQL 5.6.32 | Wildcard SSL cert (Comodo)
Moodle hosted on a sub-domain: academy.carterradley.com
Carterradley.com is the main domain on the account. When checking SSL Shopper, the certificate seems to be installed correctly on the sub-domain (http://academy.carterradley.com). Screenshot attached.
So the next steps was to change the moodle config:
1. Changed the wwwroot in config,php to https
2. tried to Add/append to a .htaccess file in the Moodle root directory:
https:// redirect.
RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://www.yoursite.com/$1 [R,L]
3. Also, changed the loginhttps option to yes and cookies to secure in Moodle administration menu.
But if I visited http://academy.carterradley.com, then the Moodle site loads up and the 'Login' button links to the secure URL https://academy.carterradley.com, but ofcourse redirects immediately like the above.
Also, I'd like to point out that at one point when we set the above, the Moodle site loaded at the secure URL but was broken, so I am assuming the css and javascript were missing.
Is there any advice the community could give me to test any other method to get SSL working on our Moodle site? If you have come across the same issue or something advice from your experience, would really appreciate that.
Thank you.