• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
.htaccess to force http using https and still get rid off index.php etc.

#1
[eluser]searain[/eluser]
I googled, to force the whole site using https. I can add these lines in .htaccess

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

But in CodeIgniter, we already use

RewriteEngine on
RewriteCond $1 !^(index\.php|images|robots\.txt)
RewriteRule ^(.*)$ /index.php/$1 [L]

To get rid of the index.php in url.

How can we merge these two requests together to have a .htaccess rewrite rules which will get rid off index.php in the url and also force to redirect http to https?

Thanks!


Messages In This Thread
.htaccess to force http using https and still get rid off index.php etc. - by El Forum - 06-19-2011, 10:42 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.