Hi,
        Try adding this code. Please note that the following 3 lines are added
before using
any  out.println() statements.
                res.addHeader("Pragma", "No-cache");
                res.addHeader("Cache-control", "no-cache");
                res.addDateHeader("Expires", 1);


And the HTML's Head part should include the following 2 meta tags
              out.println("<html><head>");
        out.println("<meta http-equiv=\"pragma\" content=\"no-cache\">");
                out.println("<meta http-equiv=\"cache-control\" 
content=\"no-cache\">");
                out.println("<title>Cache Control</title>");
                out.println("</head><body>");

Regards,
Niranjan.

-----Original Message-----
From: A mailing list about Java Server Pages specification and reference
[mailto:[EMAIL PROTECTED]]On Behalf Of Duane Morse
Sent: Wednesday, June 20, 2001 12:49 AM
To: [EMAIL PROTECTED]
Subject: Re: response.sendRedirect(...) is taking page from cache


Try adding a URL variable which has a random number as a value -- that's the
standard way
to get around caching problems (I'm sorry to say).

-----Original Message-----
From: St. Louis, Thomas (CRD) [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, June 19, 2001 12:13 PM
To: [EMAIL PROTECTED]
Subject: response.sendRedirect(...) is taking page from cache


I have a page that submits a request to a servlet and on certain conditions
the servlet performs a
response.sendRedirect(...) right back to itself.  Is there anyway to force
the browser to not grab
the page from cache.  I have the html tags
   <META name="Cachecontrol" value="no-cache"> but this still does not seem
to do anything.  Any
thoughts on how to override taking the page from cache?

Thanks for your help!
> g             GE Corporate Research & Development
> ______________________________________________
>      Tom St.Louis
>      GE Corporate Research & Development
>      One Research Circle, K1-5C39C
>      Schenectady, NY  12309
>      Phone: (518) 387-4900  Dial Comm: 8*833-4900
>      Email: [EMAIL PROTECTED]
>

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to