Closed (works as designed)
Project:
Logout Tab
Version:
7.x-1.1
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Reporter:
Created:
15 Apr 2014 at 08:50 UTC
Updated:
5 May 2014 at 08:21 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
donSchoe commentedPatch attached, it duplicates the behaviour of user_logout() but uses the custom redirect path.
Comment #2
donSchoe commentedComment #3
donSchoe commentedOk the default value 'user/logout' throws a permission denied warning. It should be changed to 'user' by default.
Comment #4
donSchoe commentedNew patch attached.
Comment #5
andypostThis variable holds a URL to redirect for logout.
no reason to implement own logout when there's core's one
Comment #6
andypostMaybe there's some module that prevents redirect for you?
I got it work fine
Comment #7
donSchoe commentedNo, wait, I dont get it.
I thought the logouttab_url is a URL where you get redirected to after you get logged out.
But you need this to point to a menu callback that logs out the user. This might be confusing.
If I want the user to redirect him to the loginscreen after logout, I need to either do 2 redirects (to /user/logout and then /user) or log out the user and after that do the redirect.
My patch does that exactly. Not sure what your intention was by setting a variable logouttab_url, if that only works for /user/logout. (Changing this variable kinda breaks the modules scope to log out the user.)
And in addition, if you are logged out, you will get an "access denied" error after this redirect to /user/logout. Because you cant log out if you are logged out already.
Comment #8
donSchoe commentedComment #9
andypost@donSchoe I get you idea about redirect url, but this out of scope for the module.
The purpose of the module is to allow user to logout via tab.
If you need to redirect user after logout then you need different module
Comment #10
donSchoe commentedOkay, no problem.
I created my own submodule for this. I was just confused about the logouttab_url variable :-)