Hi, I have a reasonable simple question for an experienced person..

I did authentication according to the cookbook, I want to access the
user id via session.

I do this in the user controller...
function login() {
  $userid = $this->Auth->user('id');
  $this->Session->write('id', $userid );
   }

Then I want to do this in the view..
<? pr($session->read('id')); ?>

to see if I get the value, but it does not seems to work in the login
function, if you place it in the view function it works, but I need
the values to be set to the session at login.

Help will be greatly appreciated. thanks
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to