Jump to content

Just bought a ssl certificate


pwired
 Share

Recommended Posts

I bought a ssl certificate for a client for 30 euro per year.

Now I have to update the .htaccess file so it will kick in.

Google made me find 3 variants and now I don't know

which one is the beste one. Since you guys have a lot

of experience can anyone advise me which is the best

one to use ?

1.

RewriteEngine On
RewriteCond %{SERVER_PORT} !443
RewriteRule (.*) https://www.example.com/require-secure/ [R]

-------------------------------------------------------------

2.

RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}

-------------------------------------------------------------

3.

SSLRequireSSL

#no non-ssl access
Redirect permanent /secure https://www.example.domain.com/secure
 

-------------------------------------------------------------

And in the second one HTTP_HOST and REQUEST_URI

are between {  }

Is that for variables ?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...