Merge pull request #107 from AlternC/albancrommer-patch-1

Update config.php to allow HTTPS on other VHOSTS
This commit is contained in:
Benjamin Sonntag 2016-08-09 16:43:37 +02:00 committed by GitHub
commit 42eac1173d
1 changed files with 1 additions and 2 deletions

View File

@ -169,8 +169,7 @@ $hooks = new m_hooks();
// https: Redirection if not calling https://!fqdn or if https is forced // https: Redirection if not calling https://!fqdn or if https is forced
if ((variable_get('force_https', '0', "This variable is set to 0 (default) if users can access the management desktop through HTTP, otherwise we force HTTPS")&&(!isset($_SERVER["HTTPS"])|| ($_SERVER["HTTPS"] != "on"))) if ((variable_get('force_https', '0', "This variable is set to 0 (default) if users can access the management desktop through HTTP, otherwise we force HTTPS")&&(!isset($_SERVER["HTTPS"])|| ($_SERVER["HTTPS"] != "on")))) {
||(isset($_SERVER["HTTPS"]) && $_SERVER["HTTPS"] == "on" && $host != $L_FQDN)) {
// do not redirect if access is not by HTTP(s) // do not redirect if access is not by HTTP(s)
if (isset($_SERVER['REQUEST_URI'])) { if (isset($_SERVER['REQUEST_URI'])) {
header("Location: https://$L_FQDN".$_SERVER['REQUEST_URI']); header("Location: https://$L_FQDN".$_SERVER['REQUEST_URI']);