Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Community Forums
 Community Discussions (All other subjects)
 Prevent caching of forum pages
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

lofty
Junior Member

USA
158 Posts

Posted - 15 March 2005 :  15:11:18  Show Profile  Visit lofty's Homepage
I'm having some problems with my forum pages getting cached. I don't want any of the .asp pages or their content to get cached, but using IE 6.0 they just keep getting cached no matter what I do.

For example, when I'm on forum.asp, I click New Topic, make a new post, hit "post new topic", and when I'm redirected back to forum.asp, the new topic doesn't show until I do a Ctrl + refresh.

Here's what I've done so far:

Client Side - WinXP SP2

I've set IE's Tools > Options to Check for Newer Versions of Stored Pages "Every Visit to the Page".

Server Side - Windows 2003 Server w/ FrontPage Server Extensions 2002

In config.asp, under the Response.Buffer = True line, I've put the following:

Response.CacheControl = "no-cache"
Response.AddHeader "Pragma", "no-cache"
Response.Expires = -1

For the website's IIS properties, in the HTTP Headers tab, Enable Content Expiration is unchecked, meaning no expiration is set.

On the root website IIS properties, in the Application Configuration dialog's Cache Options tab, I have it set to "Do Not Cache ASP files".

And just in case FPSE is screwing things up, in the Performance Tuning section, I've defined a custom tuning option where no documents are cached.

What else can I do to get IE to stop caching? Everything works as expected with FireFox and Opera.

Thanks a bunch,
Adam

-gary
Development Team Member

406 Posts

Posted - 15 March 2005 :  16:01:33  Show Profile
Response.Expires = dateadd("d", -7, Now())
Response.ExpiresAbsolute = dateadd("d", -7, Now())
Response.CacheControl = "no-cache"
Response.AddHeader "Pragma", "no-cache"

Works every time for me and covers every loophole I believe. Doesn't mean that clients or proxies MUST obey, but they should.

KawiForums.com


Go to Top of Page

lofty
Junior Member

USA
158 Posts

Posted - 15 March 2005 :  16:17:45  Show Profile  Visit lofty's Homepage
Great, that ExpiresAbsolute property really seemed to do the trick.

Thanks!
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.29 seconds. Powered By: Snitz Forums 2000 Version 3.4.07