If your logged in its:
$this->Auth->user('username');
Or you can assign a user variable to the view:
$this->set('user', $this->Auth->user());
echo $user['username'];
Hope that helps.
On Dec 11, 11:10 am, "[email protected]" <[email protected]>
wrote:
> I've been wacking my head on the wall for the past few days on this.
> I've got a basic auth login/logout system set up but for some reason
> nothing i try gets me the username. I just want to display it as in
> "Your logged in as xyz". I know it's probably something stupid and I'm
> no doubt going about it the wrong way. Any help?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, send email to [email protected]
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
-~----------~----~----~----~------~----~------~--~---