Esempio n. 1
0
 protected function before()
 {
     if (Cookie::get('is_admin') == 1) {
         $this->view->set('is_admin', 1);
     }
     $this->view->helpers->set('block', 'Hook\\CMS\\Helper::block');
     $this->view->setTemplatesDirectory(__DIR__ . '/views');
 }
Esempio n. 2
0
 protected function before()
 {
     $this->view->setTemplatesDirectory(__DIR__ . '/../views');
     $this->setLayout(Cookie::get('is_admin') == 1 ? 'admin/authenticated' : 'admin/unauthenticated');
 }