php - Use Loader class within a hook in CodeIgniter -
i have function in hook: public function checkiflogged() { $this->ci = & get_instance(); if(!$this->ci->session->userdata('logged') ){ $this->ci->load->view('common/home'); exit; } } my problem $this->ci->load->view('common/home'); doesn't load template file @ all. there resons why? i using post_controller_constructor hook. thanks, peter pre_system called during system execution. benchmark , hooks class have been loaded @ point. no routing or other processes have happened. pre_controller called prior of controllers being called. base classes, routing, , security checks have been done. post_controller_constructor called after controller instantiated, prior method calls happening. post_controller called after controller executed. display_override overrides _display() function, used send finalized page web browser @ end of system execution. permits use own disp...