public function __construct($layout, $seringue)
 {
     $this->layout = $this->set_layout($layout);
     $this->request = Kernel\Request::get_instance();
     $this->response = Kernel\Response::get_instance();
     $this->flash = Utilities\Flash::get_instance();
     $this->route = Kernel\Route::get_instance();
     $this->security = Kernel\Security::get_instance();
     $this->seringue = $seringue;
 }
Esempio n. 2
0
 public function __construct($view, $seringue)
 {
     $this->view = $view;
     $this->seringue = $seringue;
     $this->page = $this->seringue->page;
     $this->log = $this->seringue->log_nano;
     $this->dispatcher = Dispatcher::get_instance();
     $this->request = Request::get_instance();
     $this->response = Response::get_instance();
     $this->route = Route::get_instance();
     $this->flash = Utilities\Flash::get_instance();
     $this->security = Security::get_instance();
     $this->_init();
 }
Esempio n. 3
0
 public function __construct()
 {
     // Required because some times Doctrine and more generally spl_autoload_register()
     // doesn't work when used with an opcode cache (APC)
     register_shutdown_function("session_write_close");
     session_start();
     $this->container = Seringue::get_instance();
     $this->container->page = new Utilities\Page($GLOBALS['env']['environment'] == "production" ? false : true);
     $this->route = Route::get_instance();
     $this->request = Request::get_instance();
     $this->response = Response::get_instance();
     $this->log = $this->container->log_nano;
     $this->i18n = Utilities\I18N::get_instance();
     $this->set_view_engine($this->container->configuration['view']['engine']);
     $this->cache = new Cache\Cache(new Cache\File(DIR_CACHE));
     $this->get_cache_config();
     $this->security = Security::get_instance();
 }