Hello, How can I set expiring date for a file (xls, gif, etc.) so it will be downloaded from server not from cache. HTTP header? Or is there another way? Sven
Hi Sven, the constructor of images and files looks like this: def __init__(self, id, title, file, content_type='', precondition='') the optional precondition can take the id of a method which is called when the image/file is published, e.g. its index_html methods gets called. You only have to make a method in the acquisition path wich reads this (in dtml) <dtml-call "RESPONSE.setHeader('expires',_.DateTime()-1.0)"> <dtml-return "''"> or something like that. Use manage_addImage( id, file, title='', precondition='name of your method', content_type='') or manage_addFile() repectively HTH Tino Wildenhain --On Freitag, 27. April 2001 16:24 +0300 Sven Syld <Sven.Syld@stat.ee> wrote:
Hello,
How can I set expiring date for a file (xls, gif, etc.) so it will be downloaded from server not from cache. HTTP header?
Or is there another way?
Sven
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
participants (2)
-
Sven Syld -
Tino Wildenhain