codeigniter login check for all functions(tabs)
问题 i have a function for login controls. if user didnt login it redirects to login.php in my controller i have to many functions and this functions represents pages in website. so do i have to call $this->is_logged_in(); function in each function. for example: class Admin extends CI_Controller{ function index(){ $this->is_logged_in(); // works fine like this $this->load->view('admin/welcome_message'); } function users(){ $this->is_logged_in(); // works fine like this $this->load->view('admin