Solved

ASP loading form cache irritates me

Posted on 1998-11-26
4
181 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

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Deprecated and Headed for the Dustbin By now, you have probably heard that some PHP features, while convenient, can also cause PHP security problems.  This article discusses one of those, called register_globals.  It is a thing you do not want.  …
Why do we like using grid based layouts in website design? Let's look at the live examples of websites and compare them to grid based WordPress themes.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
This video teaches users how to migrate an existing Wordpress website to a new domain.

744 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

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now