On Wed, 25 Aug 1999, Steven J. Owens wrote:

[ ... ]
>      I've tried using response.setHeader() to set Expires,
> Pragma/no-cache, Cache-Control/no-store, both on the page containing
> the form and on the generated page.  Neither seems to have any
> effect.  Here's the specific code, pasted from my source:
>
>     response.setHeader("Pragma", "no-cache");
>     response.setHeader("Cache-Control", "no-store");
>     response.setHeader("Expires", "Wednesday, 29-Dec-1995 00:00:00 GMT");
[ ... ]

By my understanding of the format required of the date in the Expires
header, this is not in the right format.  Here's what I use:

   resp.setHeader("Expires", "Mon, 01 Jan 1990 06:00:01 GMT");

It has to use that format for all the components of the date, and it
has to use GMT.  You don't have to use that specific date :-).

I use this and the Pragma and Cache-Control headers as you have above,
and it works for me (in my limited testing) to prevent caching.

Milt Epstein
Research Programmer
Software/Systems Development Group
Computing and Communications Services Office (CCSO)
University of Illinois at Urbana-Champaign (UIUC)
[EMAIL PROTECTED]

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to