Welcome Guest, Not a member yet? Register   Sign In
Sessions stopped working after 2nd day
#1

[eluser]BigJoe[/eluser]
I watched some video tutorials on creating and register and login for CI. The thing is that every thing was working fine the 1st day. Then the next day I wanted to log in and test some options I added and well it looks like the sessions are not getting set. So I been reading a lot on this matter and I'm confused on this. My code is below. Any one have any ideas why this just stopped working

Code:
public function login_validation() {
        
        $this->form_validation->set_rules('username','Username','required|trim|max_lengh[50]|xxs_clean|callback_validate_user');
        $this->form_validation->set_rules('password','Password','required|trim|max_lengh[150]|xxs_clean|md5');
        
        if($this->form_validation->run()) {
            
            $data = array(
                'username'      => $this->input->post('username'),                
                'is_logged_in'  => 1                
            );
            
            $this->session->set_userdata($data);            
            
            redirect('home/index');
        } else {            
            $this->load->view('login_view');
        }      
    }



Messages In This Thread
Sessions stopped working after 2nd day - by El Forum - 12-09-2012, 09:16 PM
Sessions stopped working after 2nd day - by El Forum - 12-11-2012, 10:08 PM
Sessions stopped working after 2nd day - by El Forum - 12-11-2012, 10:23 PM



Theme © iAndrew 2016 - Forum software by © MyBB