Welcome Guest, Not a member yet? Register   Sign In
Session Data lost when redirect to a view
#2

(This post was last modified: 06-19-2017, 02:14 PM by natanfelles. Edit Reason: . )

(06-19-2017, 01:45 PM)hafizfarooq Wrote: I have setting a session in my controller  by using
PHP Code:
           $this->load->model('user_m');
 
           $ui $this->user_m->login($username$password);
 
           if ($ui) {
 
               
                $this
->load->library('session');
 
               $this->session->set_userdata('userinfo',$ui); 

But when i redirect it to my view.... it gives nothing... 
1) where's the session data goes.
2)How to get the session data in my view


Do you tried var_dump($_SESSION['userinfo']) in your view?
Reply


Messages In This Thread
RE: Session Data lost when redirect to a view - by natanfelles - 06-19-2017, 02:14 PM



Theme © iAndrew 2016 - Forum software by © MyBB