[End-Users] Force SSL: Read, please

Sparky2002b

Registered
Apr 23, 2005
2
0
151
Right, so, a few of my users have installed E-Commerce scripts and have SSL certificates; and I have WHM Autopilot.

I'd like to HTTPS:// these directories and/or subdomains.

Is this possible? How?

Thanks.
 

bmcpanel

Well-Known Member
Jun 1, 2002
546
0
316
Right, so, a few of my users have installed E-Commerce scripts and have SSL certificates; and I have WHM Autopilot.

I'd like to HTTPS:// these directories and/or subdomains.

Is this possible? How?

Thanks.
Inside of the directory that you want to be secure, you can edit .htaccess to make sure any http requests are directed to https automatically and without much fan fare.

vi .htaccess

------- copy and paste the code below into the .htaccess file -----

### Redirect to ssl
RewriteCond %{HTTPS} !=on
RewriteRule .* https://%{SERVER_NAME}%{REQUEST_URI} [R,L]

----------------- end copy/paste --------------
 

martinoo

Registered
Mar 27, 2007
1
0
151
Hello,

Where should this code be entered within the .htaccess file?
I put it at the end but it does not redirect users from http to https