Welcome Guest, Not a member yet? Register   Sign In
redirect all http:// requests to https:// (SSL)
#9

[eluser]Kobus M[/eluser]
[quote author="@robertotra" date="1329171609"][quote author="Kobus M" date="1329170243"]I got it fixed, thanks.

I did the following:

$proto = "http" . ((isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == "on") ? "s" : "") . "://";
$config['base_url'] = $proto . 'www.impero.co.za/';[/quote]

I think it is not enough: this will set all your url's to https on your internal links, but will not force redirections if someone types the url manually. The same source that you cite uses a function to force redirection if a controller is called on http.

Roberto[/quote]

I tried this. I typed the URL with https:// and then browsed around, and viewed the source, it stayed on https and all assets were loaded on https. If I then typed the URL to normal without https (only http) and browsed around, it worked as expected, all assets loaded from http://... If needed, I will follow the rest of the advice in the article. Thanks for responding, Roberto :-)

Kobus


Messages In This Thread
redirect all http:// requests to https:// (SSL) - by El Forum - 02-13-2012, 09:37 AM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-13-2012, 10:19 AM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-13-2012, 12:44 PM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-13-2012, 02:21 PM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-13-2012, 02:29 PM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-13-2012, 02:45 PM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-13-2012, 02:57 PM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-13-2012, 03:20 PM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-13-2012, 10:39 PM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-14-2012, 03:36 AM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-14-2012, 04:08 AM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-14-2012, 04:40 AM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-14-2012, 09:30 AM
redirect all http:// requests to https:// (SSL) - by El Forum - 02-16-2012, 06:04 AM



Theme © iAndrew 2016 - Forum software by © MyBB