On Monday 22 January 2007 06:00, indoven wrote:
> Thanks Hydra.
> The code was based on https://trac.cakephp.org/ticket/943.
>
> With the suggested changes it doesn't work.

I think you also forgot to assign a value to $logged.

function admin_index() {
    $username = $this->Session->read('user');
    $results = $this->User->findByUsername($username);
    $this->set('User', $results['User']);
    if ($logged) {
...

Maybe 

$username = $this->Session->read('user');
if (!empty($username)) {
    $logged = true;
} else {
    $logged = false;
}

(...or maybe you know something that I don't.)


> Perhaps I need to upgrade 
> to 1.2.
>
> Anyone done this with 1.1 and have a code sample?
>
> [snip]


Lemuel

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" 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
-~----------~----~----~----~------~----~------~--~---

Reply via email to