1. Alex Willmer
  2. trac-ticketlinks


cboos  committed 535f961

0.12.3dev: use an //Expires: ... 1999// header when `send()`ing dynamic content, for compatibility with some old proxies.

We already had the //Cache-control: must-revalidate// header, but apparently that was not always enough.

Closes #5862.

  • Participants
  • Parent commits 9ab68e5
  • Branches 0.12-stable

Comments (0)

Files changed (1)

File trac/web/api.py

View file
  • Ignore whitespace
     def send(self, content, content_type='text/html', status=200):
         self.send_header('Cache-Control', 'must-revalidate')
+        self.send_header('Expires', 'Fri, 01 Jan 1999 00:00:00 GMT')
         self.send_header('Content-Type', content_type + ';charset=utf-8')
         self.send_header('Content-Length', len(content))