comparison roundup/cgi/client.py @ 3071:b3f9dee6aa76 maint-0.8

merge from HEAD
author Richard Jones <richard@users.sourceforge.net>
date Wed, 05 Jan 2005 22:02:57 +0000
parents f4023f1cc1d6
children f6ecda229195
comparison
equal deleted inserted replaced
3070:d6b848497747 3071:b3f9dee6aa76
1 # $Id: client.py,v 1.211 2004-12-03 22:19:41 richard Exp $ 1 # $Id: client.py,v 1.211.2.1 2005-01-05 22:02:05 richard Exp $
2 2
3 """WWW request handler (also used in the stand-alone server). 3 """WWW request handler (also used in the stand-alone server).
4 """ 4 """
5 __docformat__ = 'restructuredtext' 5 __docformat__ = 'restructuredtext'
6 6
268 if url: 268 if url:
269 self.additional_headers['Location'] = url 269 self.additional_headers['Location'] = url
270 self.response_code = 302 270 self.response_code = 302
271 self.write_html('Redirecting to <a href="%s">%s</a>'%(url, url)) 271 self.write_html('Redirecting to <a href="%s">%s</a>'%(url, url))
272 except SendFile, designator: 272 except SendFile, designator:
273 self.serve_file(designator) 273 try:
274 self.serve_file(designator)
275 except NotModified:
276 # send the 304 response
277 self.request.send_response(304)
278 self.request.end_headers()
274 except SendStaticFile, file: 279 except SendStaticFile, file:
275 try: 280 try:
276 self.serve_static_file(str(file)) 281 self.serve_static_file(str(file))
277 except NotModified: 282 except NotModified:
278 # send the 304 response 283 # send the 304 response

Roundup Issue Tracker: http://roundup-tracker.org/