Author: fw Date: 2005-10-20 09:02:46 +0000 (Thu, 20 Oct 2005) New Revision: 2484 Modified: lib/python/web_support.py Log: r627@deneb: fw | 2005-10-14 10:33:41 +0200 lib/python/web_support.py (RedirectResult): Support non-permanent redirections. Modified: lib/python/web_support.py ==================================================================--- lib/python/web_support.py 2005-10-20 09:02:32 UTC (rev 2483) +++ lib/python/web_support.py 2005-10-20 09:02:46 UTC (rev 2484) @@ -529,8 +529,11 @@ class RedirectResult(Result): """Permanently redirects the browser to a new URL.""" - def __init__(self, url): - self.status = 301 + def __init__(self, url, permanent=True): + if permanent: + self.status = 301 + else: + self.status = 302 self.url = str(url) def flatten(self, write):