Prevent IE caching

Posted by Parhs on Stack Overflow See other posts from Stack Overflow or by Parhs
Published on 2010-05-17T12:21:58Z Indexed on 2010/05/17 13:20 UTC
Read the original article Hit count: 359

Filed under:
|
|

I am developing a Java EE web application using Struts. The problem is with Internet Explorer caching. If an user logs out he can access some pages because they are cached and no request is made. If I hit refresh it works fine. Also if an user goes to login page again it won't redirect him because that page is also cached.

Two solutions come to my mind:

  1. Writing an Interceptor (servlet filter like) to add to response header no-cache etc.
  2. Or or put <meta> tags at each page.

Which one should I do?

© Stack Overflow or respective owner

Related posts about java

Related posts about struts