Solved

Cache a web page even if the browser setting is new page every visit to the page

Posted on 1999-01-05
6
188 Views
Last Modified: 2010-04-09
Is there a way with meta tags or cache-control or any other way to force the browser to use a browsercached copy of a page instead of loading a fresh one if the browser setting is set for a new page every visit to the page ? If a user fills in a form and get an error response i would like it if the user could press the back button and get the form with the data that the user already has filled in - not an empty form. Thanks in advance !
0
Comment
Question by:adbkp
[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
6 Comments
 
LVL 4

Expert Comment

by:martinag
ID: 1841298
In Netscape, the information will be there no matter if the cache is on or off. In IE3, the information will be away (not sure about IE4/5).

Martin
0
 
LVL 6

Expert Comment

by:PBall
ID: 1841299
It sticks too in IE4.  So what's this question good for then hehe.
0
 

Author Comment

by:adbkp
ID: 1841300
Adjusted points to 200
0
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!

 
LVL 4

Accepted Solution

by:
jbrugman earned 200 total points
ID: 1841301
you can use the following(a lot of work though :-)
mind the difference between 'and " !
It's not real caching, but you'll get the idea.

<HTML>

<SCRIPT LANGUAGE="JavaScript">
function cachedpage() {
document.write("<HTML>");
document.write("<BODY BACKROUND='back.jpg'>");
document.write("<FONT FACE='ARIAL'>the cached page</FONT>");
document.write("</BODY></HTML>");
</SCRIPT>

<BODY>
<FORM>
<INPUT TYPE="BUTTON" onClick"="cachedpage()"
</FORM>
</BODY>
</HTML>
0
 
LVL 4

Expert Comment

by:martinag
ID: 1841302
I don't get the idea.

BTW, that script won't work with...err...most browsers (maybe none (don't know that much about IE)). You'll have to open() and close() the document:
  document.open();
  document.write(...);
  document.close();

Martin
0
 
LVL 4

Expert Comment

by:jbrugman
ID: 1841303
You are able to read the form, pass the data to hidden fields, then put them in a pre-written page, like document.write("name <INPUT TYPE=tekst VALUE="+namefield+">") when hitting back, the data is still in the form. (it's no real caching).
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
html border input line 7 26
Date on a table 16 34
Two decimal 5 26
Check input text, Number 6 30
SASS allows you to treat your CSS code in a more OOP way. Let's have a look on how you can structure your code in order for it to be easily maintained and reused.
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)

756 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