protected function handleSSLRedirection()
{
// Specifically disable for the opt out iframe
if (Piwik::getModule() == 'CoreAdminHome' && Piwik::getAction() == 'optOut') {
return;
}
// Disable Https for VisitorGenerator
if (Piwik::getModule() == 'VisitorGenerator') {
return;
}
if (Common::isPhpCliMode()) {
return;
}
// proceed only when force_ssl = 1
if (!SettingsPiwik::isHttpsForced()) {
return;
}
Url::redirectToHttps();
}