• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Ion Auth - logout problem

Hi all,

I do not know if I am missing something, but when I create new user and log in with new users credentials and try to retrieve users details I get administrators info which I used before to log in. As well when I log myself out I still can see users info. For logging out I use:
Do I need somehow add some extra code to kill session or what ? Thanks a lot.

I think the logout() has destroy session.

[eluser]Jason Hamilton-Mascioli[/eluser]
Make sure to add this to the top of your protected/secure controller page...

if (!$this->ion_auth->logged_in())


Should this one get current logged in user email ? Or first row user email in DB ?
$user = $this->ion_auth->user()->row();
  echo $user->email;

with out an id it will get the current logged in user.

ok I found my mistake thanks for everyone

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

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