private static function ShrinkTheWebSettingsPageController::shrinktheweb_is_ssl in ShrinkTheWeb 8
Check https function
1 call to ShrinkTheWebSettingsPageController::shrinktheweb_is_ssl()
- ShrinkTheWebSettingsPageController::shrinktheweb_check_scheme_options in src/
Controller/ ShrinkTheWebSettingsPageController.php - Check scheme function
File
- src/
Controller/ ShrinkTheWebSettingsPageController.php, line 23
Class
- ShrinkTheWebSettingsPageController
- Class ShrinkTheWebSettingsPageController.
Namespace
Drupal\shrinktheweb\ControllerCode
private static function shrinktheweb_is_ssl() {
if (!empty($_SERVER['HTTPS']) && strcasecmp($_SERVER['HTTPS'], 'off') != 0) {
return TRUE;
}
elseif (isset($_SERVER['SERVER_PORT']) && '443' == $_SERVER['SERVER_PORT']) {
return TRUE;
}
elseif (isset($_SERVER['HTTP_X_FORWARDED_PROTO']) && strcasecmp($_SERVER['HTTP_X_FORWARDED_PROTO'], 'https') == 0) {
return TRUE;
}
return FALSE;
}