Linux Sysadmin Blog

Linux Sysadmin Blog header image 4

Entries from March 9th, 2009

Force url to use SSL/https

March 9th, 2009 · 10 Comments · hosting

In some cases you would want to have your site use SSL (https://) at all times you can do this by using: 1.) Using Htaccess/mod_rewrite. You only need to create a .htaccess file on your home directory and add the codes below: <IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{HTTPS} !=on RewriteRule ^/(.*) https://%{SERVER_NAME}/$1 [R,L] </IfModule> The [...]

[Read more →]

Tags: