So a little background: my database was totally wiped on my test
platform, and I had failed to keep a backup (stupid, I know).
At any rate, I failed to realize that although I had set all actions
to be allowed in the app controller while fixed everything, I had
(before) set just one of my actions in the user controller to be
allowed. Subsequently, it locked out everything else in the user
controller, including the login/logout.
So even though I THOUGHT I was allowing all actions, I wasn't. I had
the ACL set to allow those actions before the database reset happened,
so I never noticed that I was controlling it poorly.
On Oct 22, 2:55 pm, jsalonen <joni.salo...@gmail.com> wrote:
> Is it possible then that the user controller's logout method is not
> being called? Perhaps you can printing something to the log to
> verify:
>
> function logout()
> {
> $this->log("I'm trying to log out");
> $this->Session->setFlash(lang('You have logged out.'));
> $url = $this->Auth->logout();
> $this->log($url);
> $this->redirect($url);
> }
>
> On Oct 22, 1:33 am, xtraorange <xtraora...@gmail.com> wrote:
>
>
>
>
>
>
>
> > It's showing me my username where I have it displayed at the top
> > right, and giving me the message saying I can't register or login
> > because I'm already logged in when I try to do either of those. So I
> > have to assume that I'm still logged in. :P
>
> > On Oct 21, 5:36 pm, jsalonen <joni.salo...@gmail.com> wrote:
>
> > > Are you sure logoout is not logging you out? You can check with:
>
> > > $this->Session->read($this->Auth->sessionKey)
>
> > > (AuthComponent uses the session to store information about the logged
> > > in user)
>
> > > On Oct 21, 11:58 pm, xtraorange <xtraora...@gmail.com> wrote:
>
> > > > Howdy all,
>
> > > > I have a very standard logout method (see below) in my user
> > > > controller. But when I go to my logout (which used to work the last
> > > > time I tested it) I just get forwarded to the root with no flash
> > > > message and no actual logout. Any ideas?
>
> > > > function logout()
> > > > {
> > > > $this->Session->setFlash(lang('You have logged out.'));
> > > > $this->redirect($this->Auth->logout());
>
> > > > }
>
> > > > What on earth could I have done to cause this failing logout issue?
Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.
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
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
No comments:
Post a Comment