function __construct() { parent::__construct(); $tpl_dir = isset($_SERVER["DOCUMENT_ROOT"]) ? $_SERVER["DOCUMENT_ROOT"] . '/templates/' : ''; if (!empty($tpl_dir) && is_dir($tpl_dir)) { $this->template_dir = $tpl_dir; } $this->assign('tpl_header', $this->template_dir . 'header.html'); $this->assign('tpl_footer', $this->template_dir . 'footer.html'); $this->assign('user', Sp_Admin_User::getUser()); $request = Request::current(); $this->assign('ancient_browser', preg_match("#MSIE [1-8]\\.#", $request->getAgent())); }