[eluser]Unknown[/eluser]
Hi,
I just enabled saving sessions in DB:
Code:
$login_info=array('logged_in_user_id' => $user_result['u_id'],
'logged_in_username'=> $user_result['u_username']);
$this->session->set_userdata('login',$login_info); // after this the session will be stored in db but I cant have access to it..
But I have problem with this code:
Code:
if(!empty($this -> session -> userdata('login')))
{
echo "login true";
} else {
echo "login false"; // I always get this one!
}
according to my above explanation:
1- is it a secure way for manipulating login process in codeigniter?
2- What should I do to get the db session data and get rid of the problem above?
Your answer is appreciated,
Warm regards