From 8b5ccd302bd1497de721a25e4ce086bebf95173f Mon Sep 17 00:00:00 2001 From: tbrehm <t.brehm@ispconfig.org> Date: Sun, 08 Jun 2008 15:32:42 -0400 Subject: [PATCH] Fixed a problem with the logout when the php session has ended. --- interface/lib/app.inc.php | 7 ++++++- 1 files changed, 6 insertions(+), 1 deletions(-) diff --git a/interface/lib/app.inc.php b/interface/lib/app.inc.php index fc63f02..dff1bd7 100644 --- a/interface/lib/app.inc.php +++ b/interface/lib/app.inc.php @@ -55,7 +55,7 @@ } //* Start the session - if($conf["start_session"] == true) { + if($this->_conf['start_session'] == true) { session_start(); //* Initialize session variables @@ -63,6 +63,8 @@ if(empty($_SESSION['s']['theme'])) $_SESSION['s']['theme'] = $conf['theme']; if(empty($_SESSION['s']['language'])) $_SESSION['s']['language'] = $conf['language']; } + + $this->uses('auth'); } public function uses($classes) @@ -176,6 +178,9 @@ if(isset($_SESSION['s']['user']) && $_SESSION['s']['user']['typ'] == 'admin') { $this->tpl->setVar('is_admin', 1); } + if(isset($_SESSION['s']['user']) && $this->auth->has_clients($_SESSION['s']['user']['userid'])) { + $this->tpl->setVar('is_reseller', 1); + } } } // end class -- Gitblit v1.9.1