How to Disable Browser cache in JSP
We can disable webpage being cached by browser by setting the header in JSP.
Just add the below line in top of the JSP page. This code will preventing cache from browser and proxy server.
response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
response.setHeader("Pragma","no-cache"); //HTTP 1.0
response.setDateHeader ("Expires", 0); //prevents caching at the proxy server