|
-
Aug 22nd, 2005, 10:21 PM
#1
Thread Starter
Hyperactive Member
Caching in ASP and ASP.NET
Hi,
In ASP, I always include the following lines in every page in order to force the page to reload in every visit:
Response.Buffer = true
Response.CacheControl = "no-cache"
Response.AddHeader "Pragma", "no-cache"
Response.Expires = -1
Is it necessary to do the same thing in ASP.NET?
I see that 'Buffer' is available as a property for 'DOCUMENT' in VS.NET, but not the others. Is there any standard way for this?
Thx!!
-
Aug 23rd, 2005, 01:09 AM
#2
Re: Caching in ASP and ASP.NET
You can use that same code, or you can simply try this:
VB Code:
Response.Cache.SetCacheability(HttpCacheability.NoCache)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|