Ben,
I don't think it is a problem with recompiling the page.  It seems that
data is posted to the page and it has some headers that cause it not to be
cached.  The problem is caused by the fact that you are navigating to the
page using the back button.  Check the headers by viewing the source of the
page in a browser.

Regards,

Richard

At 05:46 PM 1/2/2002 -0500, you wrote:
>Hello JSP gurus:
>
>I have an web-server application that displays a linear sequence of 5 pages.
>I can use
>the back button and move through most of the pages I've already seen, but
>one of the pages
>acts differently than all the others.  This page _always_ asks me to refresh
>(ie. when I hit the
>troublesome page I get a message on my browser saying "Warning: Page has
>expired",
>and I have to hit the refresh button to see anything at all).  When I
>request the refresh, the
>server pauses for a length of time that makes me think it's regenerating the
>servlet from
>the jsp code.  This makes the application seem clunky and slow, and I'm
>hoping that one
>of you can tell me how to get around this behavior.
>
>My theory about what's wrong:
>I'm guessing that the date on the compiled JSP is updated each time the
>program delivers
>a response to the user, and therefore every time I hit the page a subsequent
>time the browser
>checks the date on the page in the cache, sees that it's older than the date
>in of the servlet,
>and forces the JSP to recompile.
>
>What I've tried:
>Changing header values, to try to get the browser to cache the page.
>Changing various meta tags to convince the browser that the page doesn't
>expire until 2009.
>Changing all manner of parameters in my browser (I use IE 5.5).
>Searching various list archives with key words like 'invalidate', 'date',
>'cache', etc. for somebody
>else who might have already solved this problem.  At the least, does
>somebody have a better
>idea about key words I might use to search the archives?
>
>Background:
>The application isn't small, and uses some semblance of an MVC architecture:
>all requests
>come to a 'front controller' servlet, and then get farmed out to JSPs where
>the output is constructed.
>Usually the first servlet forwards the call to another servlet which
>forwards the call to a JSP, which
>then includes various sub-JSPs to construct the final response.  Is all this
>complexity causing my
>application to confuse itself?
>
>Final words:
>How can this be?  There's nothing very tricky on the offending page (some
><select>s, a few buttons,
>and a bunch of Javascript to try to make the web page seem dynamic), so why
>does it behave differently
>than my other pages?  Any hints?
>
>Thanks,
>Ben
>
>===========================================================================
>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://archives.java.sun.com/jsp-interest.html
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.jsp
>  http://www.jguru.com/faq/index.jsp
>  http://www.jspinsider.com

===========================================================================
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://archives.java.sun.com/jsp-interest.html
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.jsp
 http://www.jguru.com/faq/index.jsp
 http://www.jspinsider.com

Reply via email to