05-16-2012, 09:39 PM
[eluser]weboap[/eluser]
using session is the most common.
http://ellislab.com/codeigniter/user-gui...sions.html
then
using session is the most common.
http://ellislab.com/codeigniter/user-gui...sions.html
Code:
$newdata = array(
'username' => 'johndoe',
'email' => '[email protected]',
'logged_in' => TRUE
);
$this->session->set_userdata($newdata);
then
Code:
$logged_in = $this->session->userdata('logged_in');
if(!$logged_in){
.......
}
else
{
.......
}