codeigniter redirect url to point to https |
[eluser]Unknown[/eluser]
I have an app that needs to be behind an https. I have the ssl so that's all set.. If the person specifies https://www... then everything is fine, but when the person doesn't specify https://www.. then i need to redirect them to the https. I'd like to do this with the .htaccess foldder, but every time i set it up the index.php page breaks and the browser attempts to serve up a .phtml.part file for me to download... help! this is the rewrite: Code: RewriteEngine on
[eluser]Jamie Rumbelow[/eluser]
You can use a simple helper method which you can call on any of your controller links. Credit to @nevercraft on the forums for this: Code: if ( ! function_exists('force_ssl')) |
Welcome Guest, Not a member yet? Register Sign In |