assign('ErrorMessage', $Exception->getMessage()); $smarty->assign('ErrorFile' , $Exception->getFile()); $smarty->assign('ErrorLine' , $Exception->getLine()); $smarty->assign('ErrorTrace' , $Exception->getTrace()); $Output = $smarty->fetch('AdminError.tpl'); } if ($template != "") { $smarty = smarty_init(dirname(__FILE__).'/../html/admin/templates', false); $smarty->assign('Output', $Output); echo $smarty->fetch($template); } else { echo $Output; } } function admin_logout() { unset($_SESSION['_ADMIN']); }