rewrite the HTTP_X_FORWARDED_PROTO test to just make it part of the if instead of modifying SERVER['HTTPS']
This commit is contained in:
parent
87f68e4a5b
commit
eb610cd3a1
|
@ -51,9 +51,12 @@ require_once( 'includes/Event.php' );
|
||||||
require_once( 'includes/Group.php' );
|
require_once( 'includes/Group.php' );
|
||||||
require_once( 'includes/Monitor.php' );
|
require_once( 'includes/Monitor.php' );
|
||||||
|
|
||||||
if ($_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https') $_SERVER['HTTPS']='on';
|
|
||||||
|
|
||||||
if ( isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == 'on' ) {
|
if (
|
||||||
|
(isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == 'on')
|
||||||
|
or
|
||||||
|
($_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https')
|
||||||
|
) {
|
||||||
$protocol = 'https';
|
$protocol = 'https';
|
||||||
} else {
|
} else {
|
||||||
$protocol = 'http';
|
$protocol = 'http';
|
||||||
|
|
Loading…
Reference in New Issue