diff --git a/classes/handler/public.php b/classes/handler/public.php index 8440bc35..72b70647 100644 --- a/classes/handler/public.php +++ b/classes/handler/public.php @@ -263,7 +263,11 @@ class Handler_Public extends Handler { function logout() { logout_user(); - header("Location: index.php"); + $location = 'index.php'; + if(defined('LOGOUT_LOCATION')) { + $location = LOGOUT_LOCATION; + } + header("Location: $location"); } function share() { diff --git a/config.php-dist b/config.php-dist index 7a076d97..0ffe4677 100644 --- a/config.php-dist +++ b/config.php-dist @@ -90,6 +90,10 @@ // If set to true, users won't be able to set application language // and settings profile. + define ('LOGIN_LOCATION', 'index.php'); + // When a user logs out, redirect to this location. This is useful when you have some central + // authentication system, and you want to reach the main logout page + // ********************* // *** Feed settings *** // *********************