Thanks a lot,
thats the better way.
Marcus Radisch
--~--~-~--~~~---~--~~
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
if you are using the Auth component for user authentification, you can
check if a user is logged in or not simply by using:
$session->check('Auth.User.id')
as a condition in your if clause
On Feb 19, 5:19 pm, amarradi wrote:
> I found the solution
>
> I set an username on an variable, and after
I found the solution
I set an username on an variable, and after Logout this variable i set
to null
:)
if(!empty($username)) {
echo $html->link('Logout', array
('controller'=>'users','action'=>'logout'));
} else {
echo $html->link('Login', array
('controller'=>'users','action'=>'login'));
}
Hello,
i want that my login link will be an logout link when a user with this
browser is login in.
When he is logout the link should show login. And if he is login the
link should show logout
I tried
debug ($session->read()); die;
but there is no state variable.
Which variable can i use for t