I misunderstood you!
My solution is to use a route, defined as:
Router::connect('/', array('controller' => 'users', 'action' =>
'logout'));
in my routes.php, thus any access at the root gives me the login form
using the users controllers logout function, which contains only:
$this->Session->destroy();
$this->redirect($this->Auth->logout());
Thus producing no message upon showing the login form!
On the other hand, if the visitor tries to reach for example /requests/
index, the auth correctly directs the user to the login form, with a
message to login first!
Enjoy,
John
On Mar 30, 10:25 pm, iFeghali <[email protected]> wrote:
> Hello John,
>
> Thanks for the answer but I don't see how it could help me. Can you
> please clarify ?
>
> On 30 mar, 15:13, John Andersen <[email protected]> wrote:
>
> > Use thishttp://book.cakephp.org/view/385/logoutasthe redirect!
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---