Solved

ASP loading form cache irritates me

Posted on 1998-11-26
4
189 Views
Last Modified: 2013-12-25
I have one ASP with a button. After pressing the button, onclick event fires and sets window.location.href to another ASP page. That page should display data from the database, but it displays the old version of page with old data form IE's cache. How can I force the page to refresh after loading or how can I force it to always get the fresh data regardless what's in the cache?

Bocian...
0
Comment
Question by:Bocian
4 Comments
 
LVL 2

Expert Comment

by:vendrig
ID: 1856759
Are you sure it's IE cache? Because there's a server cache as well. You can turn it off, but I can't tell you how at this moment. It's in the docs though, or maybe a kind soul here can tell you.
0
 

Author Comment

by:Bocian
ID: 1856760
It's IE's cache because I can switch it off in Internet settings on my local computer. But I cannot rely on the fact that everybody will have this cache disabled. In most cases it's enabled. When i request the page as follows:
 http:// bla bla bla/mycleverpage.asp?param=value&param2=value2
and the same request is buffered, it is displayed from the cache with the old data, but the actual data has changed meanwhile...
0
 
LVL 2

Accepted Solution

by:
Wiz_of_Oz earned 100 total points
ID: 1856761
to skip the cacheing of a page insert the following line into your HEAD section...

<meta http-equiv="PRAGMA" value="NO-CACHE">
0
 

Expert Comment

by:bslavin
ID: 1856762
Or you can use:

<%Response.Expires = 0%>

Which will not allow the server to cache the page.
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

Although it can be difficult to imagine, someday your child will have a career of his or her own. He or she will likely start a family, buy a home and start having their own children. So, while being a kid is still extremely important, it’s also …
Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
This tutorial demonstrates how to identify and create boundary or building outlines in Google Maps. In this example, I outline the boundaries of an enclosed skatepark within a community park.  Login to your Google Account, then  Google for "Google M…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

790 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