[Twisted-web] Sessions with LivePage?

Donovan Preston dp at ulaluma.com
Mon Jul 25 00:27:03 MDT 2005

On Jul 24, 2005, at 7:51 PM, Chris (FeedTagger) wrote:

>>> I don't know of any reason why there would be an issue using  
>>> sessions
>>> with livepage. In fact, my "Secret Project" uses them. Just as an
>>> experiment, you might want to try wrapping the root resource in a
>>> nevow.guard.SessionWrapper so that you get guard's modern  
>>> sessions,  not
>>> the old crufty twisted-web one.
> That seemed to fix the problems - Now you've got me using guard I have
> more questions ;)
> How can I specify the URL to redirect to when a user logs in or logs
> out? For example if i browse to /index and login, I want to be
> redirected to /home. If I'm at /some-page and click logout I still
> want to be at that page (not sent back to /index) - or sometimes i
> will want to redirect on logout. I'm struggling to see how this is
> possible at the moment.

If you post the login form to a url in the form of /__login__/foo/bar/ 
baz you will get redirected to /foo/bar/baz after login. I think the  
same is also true of logout.


More information about the Twisted-web mailing list