diff --git a/main/inc/lib/template.lib.php b/main/inc/lib/template.lib.php index 390e0cb1ee..f5ab2a14b6 100755 --- a/main/inc/lib/template.lib.php +++ b/main/inc/lib/template.lib.php @@ -737,7 +737,11 @@ class Template //Preparing values for the menu //Logout link - $this->assign('logout_link', api_get_path(WEB_PATH).'index.php?logout=logout&uid='.api_get_user_id()); + if (isset($_configuration['hide_logout_boton']) && $_configuration['hide_logout_boton'] == false) { + $this->assign('logout_link', api_get_path(WEB_PATH).'index.php?logout=logout&uid='.api_get_user_id()); + } else { + $this->assign('logout_link', null); + } //Profile link if (api_get_setting('allow_social_tool') == 'true') { diff --git a/main/install/configuration.dist.php b/main/install/configuration.dist.php index 22480a9934..a8275fef5a 100755 --- a/main/install/configuration.dist.php +++ b/main/install/configuration.dist.php @@ -249,3 +249,5 @@ $_configuration['system_stable'] = NEW_VERSION_STABLE; //$_configuration['default_template'] = 'default'; // (main/template/default) // Show reduce LP report //$_configuration['lp_show_reduced_report'] = false; +// Hide the logout button +//$_configuration['hide_logout_boton'] = true; diff --git a/main/template/default/layout/menu.tpl b/main/template/default/layout/menu.tpl index 74cc1a65ec..9017212088 100755 --- a/main/template/default/layout/menu.tpl +++ b/main/template/default/layout/menu.tpl @@ -34,11 +34,13 @@ {% endif %} + {% if logout_link is not null %}
  • + {% endif %} {% else %} {# Direct login to course - no visible if logged and on the index page #}