Hey all,
MODX Revolution 2.2.1-pl, standard login package.
User logs in fine. Logout, which redirects to home.html?service=logout, works and they appear logged out i.e. menu changes back to login (from "my account")
However $modx->user->get('id') is still set to a value > 0.
I notice in the login package it uses $modx->user->hasSessionContext($modx->context->get('key')) which is false when not logged in and I am changing a couple of snippets to use that.
But why does user->get('id') still have a value, or was I using it incorrectly?
[ed. note: xxxmicrobexxx last edited this post 13 years, 3 months ago.]
-
☆ A M B ☆
- 24,524 Posts
Are you logged in as a Manager user when doing this? That can cause some oddities in dealing with users.
Yep, that was it...sigh...I spent ages trying to sort out what was going on. Thanks for the suggestion.