Force Reload on JSP Pages?

  • Thread starter Emery Z. Balint Jr.
  • Start date
E

Emery Z. Balint Jr.

I've noticed this odd behavior when working on my Web application, where if
a JSP page was cache-able then the servlet would never run. I guess this is
normal since the browser assumes the page doesn't change, so it doesn't put
a request in to the server.

But I'm curious. Is there some command or perhaps a server config that would
allow all JSP pages, whether cached or not, to always reload? I hope this
makes sense, if more is required, I'd be glad to explain more. Thanks for
any assistance in advance!

Emery.
/\^/\^/\
Sun Certified Java Programmer
www.websamba.com/javarobotics/
E-stronomy - Astronomical Resources
www.websamba.com/e-stronomy/
 
B

Benny

Hi,

It seems this behavior related the cached JSP page. Can the
problem be solved by setting all the pages with no-cache by using META
tag?

Benny
 
E

Emery Z. Balint Jr.

Thanks for the reply, I'll try the meta-tag version. I was using the
following myself in the JSP pages:

response.setHeader("Cache-Control", "no-cache");
response.setHeader("Pragma", "no-cache");
response.setDateHeader("Expires", 0);

Emery.
/\^/\^/\
Sun Certified Java Programmer
www.websamba.com/javarobotics/
E-stronomy - Astronomical Resources
www.websamba.com/e-stronomy/
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top