N°3668 - fix an improper redirection to the homepage when iTop is behind a reverse proxy

This commit is contained in:
bruno-ds
2021-03-04 09:39:48 +01:00
parent 1f26b59d90
commit 1429792690

View File

@@ -685,7 +685,7 @@ class LoginWebPage extends NiceWebPage
public static function HTTPReload()
{
$sOriginURL = $_SERVER['REQUEST_SCHEME'] . '://' . $_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI'];
$sOriginURL = utils::GetCurrentAbsoluteUrl();
if (!utils::StartsWith($sOriginURL, utils::GetAbsoluteUrlAppRoot()))
{
// If the found URL does not start with the configured AppRoot URL