Hi there,
it would be nice to have the _next variable working for user/logout
like it works for user/login

In my case i always show a menu on top, whenever a user wants to log
in I open the login page an after a sucessfull login I redirect them
to wherever they have been before, doing the same for a logout is not
possible

here is what my menu looks like

if 'auth' in globals():
    if not auth.is_logged_in():
       response.menu_auth = [
           [T('Login'), False, auth.settings.login_url+"?
_next="+request.env.request_uri,# redirect works
            [
                   [T('Register'), False,
                    URL(request.application,'default','user/
register')],
                   [T('Lost Password'), False,
                    URL(request.application,'default','user/
retrieve_password')]]
            ],
           ]
    else:
        response.menu_auth = [
            ['User: '+auth.user.first_name,False,None,
             [
                    [T('Logout'), False,
                     URL(request.application,'default','user/logout')
+"?_next="+request.env.request_uri],# redirect does not work!
                    [T('Edit Profile'), False,
                     URL(request.application,'default','user/
profile')],
                    [T('Change Password'), False,
                     URL(request.application,'default','user/
change_password')]]
             ],
            ]

--

You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en.


Reply via email to