• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
MY_controller problem

#8
[eluser]weboap[/eluser]
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
{
.......
}




Messages In This Thread
MY_controller problem - by El Forum - 05-16-2012, 09:17 AM
MY_controller problem - by El Forum - 05-16-2012, 09:23 AM
MY_controller problem - by El Forum - 05-16-2012, 09:32 AM
MY_controller problem - by El Forum - 05-16-2012, 09:38 AM
MY_controller problem - by El Forum - 05-16-2012, 09:42 AM
MY_controller problem - by El Forum - 05-16-2012, 02:43 PM
MY_controller problem - by El Forum - 05-16-2012, 09:27 PM
MY_controller problem - by El Forum - 05-16-2012, 09:39 PM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.