Commit fdd8d1bc authored by 's avatar

Removed Last-Modified, which appears to be post-processed by Apache and

causes caching problems with clients :(
parent 9bebeb24
...@@ -84,7 +84,7 @@ ...@@ -84,7 +84,7 @@
############################################################################## ##############################################################################
"""Image object""" """Image object"""
__version__='$Revision: 1.72 $'[11:-2] __version__='$Revision: 1.73 $'[11:-2]
import Globals, string, struct, content_types import Globals, string, struct, content_types
from OFS.content_types import guess_content_type from OFS.content_types import guess_content_type
...@@ -99,6 +99,7 @@ from Acquisition import Implicit ...@@ -99,6 +99,7 @@ from Acquisition import Implicit
from DateTime import DateTime from DateTime import DateTime
manage_addFileForm=HTMLFile('imageAdd', globals(),Kind='File',kind='file') manage_addFileForm=HTMLFile('imageAdd', globals(),Kind='File',kind='file')
def manage_addFile(self,id,file,title='',precondition='',REQUEST=None): def manage_addFile(self,id,file,title='',precondition='',REQUEST=None):
"""Add a new File object. """Add a new File object.
...@@ -169,7 +170,6 @@ class File(Persistent,Implicit,PropertyManager, ...@@ -169,7 +170,6 @@ class File(Persistent,Implicit,PropertyManager,
Returns the contents of the file or image. Also, sets the Returns the contents of the file or image. Also, sets the
Content-Type HTTP header to the objects content type. Content-Type HTTP header to the objects content type.
""" """
if self.precondition and hasattr(self,self.precondition): if self.precondition and hasattr(self,self.precondition):
# Grab whatever precondition was defined and then # Grab whatever precondition was defined and then
# execute it. The precondition will raise an exception # execute it. The precondition will raise an exception
...@@ -180,7 +180,7 @@ class File(Persistent,Implicit,PropertyManager, ...@@ -180,7 +180,7 @@ class File(Persistent,Implicit,PropertyManager,
else: else:
c() c()
RESPONSE.setHeader('content-type', self.content_type) RESPONSE.setHeader('content-type', self.content_type)
# RESPONSE.setHeader('Last-Modified', rfc1123_date(self._p_mtime)) RESPONSE.setHeader('Last-Modified', rfc1123_date(self._p_mtime))
return self.data return self.data
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment