?
Solved

Need Caching in IE 6.0

Posted on 2004-04-12
7
Medium Priority
?
141 Views
Last Modified: 2010-04-01
Hi
   One of the screens in our application requires caching. i.e. User will enter data in input screen & click "Create" button. The data will be submitted to the server and re-displayed in the same screen with the previously entered (We havent done anything programmatically to re-display the data).  We've coded for no-caching in an include file and included it in all the pages. Because of the above requirement, the above jsp overrides no-caching by using the following

      response.setHeader("Cache-Control","store");
      response.setHeader("Pragma","cache");
      response.setDateHeader("Expires", 20160);

This works fine. The data is re-displayed after the user clicks create.  

The screen contains a button that will invoke another pop-up screen that will fill one of the fields in the base screen. Once the pop-up screen is invoked and closed, the caching technique doesn't work. i.e. the data is not re-displayed after clicking "Create" button. This problem occurs even if a blank page is invoked in the pop up window.

Is there any possible solution to overcome this?

Note:-  In Mozilla, the data is automatically cached even without the above three lines. i.e. it re-displays the data after clicking "Create" . It works fine even if the popup window is invoked. Hence, the user community wants the same behavior in IE too!!!!

0
Comment
Question by:athuranand
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
7 Comments
 
LVL 53

Expert Comment

by:Ryan Chong
ID: 10806543
Require caching? Why dont just simply remove those 3 lines above?..
0
 

Author Comment

by:athuranand
ID: 10808281
If the above three line are removed, then caching wont happen.
0
 
LVL 13

Expert Comment

by:copyPasteGhost
ID: 10818515
I would use a java bean

load all the values you want into a java bean and then load them from the bean on to your page.. you can keep the same variables for the whole session..

when using beans 3 things to keep in mind.

1)   you need a package.
      add this statement to all your .java files.
      package myPac;

2)   you must declare this at the top of your .jsp page.
      <jsp:useBean id = "tracking" scope = "session" class = "myPac.myClass" />

3)   You must be using this directory structure

-jspfiles
-WEB-INF
          -classes
              -myPac
                   -myClass.class

I can explain this futhur if you are not familiar with java beans..
let me know and I'll get back to you as soon as possible.
Cheers
Ghost
0
 

Author Comment

by:athuranand
ID: 10861690
Hi Ghost
   Thanks for your reply. I'm faimiliar with java beans and also reloading technique using beans. I'm just trying to satisfy some requirements on already existing code. Moreover this page is being reused and dynamically generated depending upon the type of entity. So, using beans at this stage doesnt work. But thanks for your reply.
0
 
LVL 1

Accepted Solution

by:
KartikShah earned 2000 total points
ID: 10919263
Normally, you are on the mercy of the browser, what data it displays in the form fields. i.e. the browser, can either display the last values posted, or the default values associated to each field i.e. the value present in the value attribute, which in your care is empty.

If you want to provide a consistent output, irrespective of the browser's decision, I would suggest you, you can load the page again, with the submitted values as the default values.

This will give confidence, that irrespective of the browser being used, the functionality will be the same. :)
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

An introduction to the wonderful sport of Scam Baiting.  Learn how to help fight scammers by beating them at their own game. This great pass time helps the world, while providing an endless source of entertainment. Enjoy!
Introducing Priority Question, our latest feature.
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…
Suggested Courses
Course of the Month9 days, 23 hours left to enroll

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question