disallow page level cache
-
Hi there I am in urgent need to know how to disable page level caching in a user control. Please provide asp.net 2.0 specific solution.
-
Hi there I am in urgent need to know how to disable page level caching in a user control. Please provide asp.net 2.0 specific solution.
these code may help u to remove page from cache. these code r write into Page Load event
if (Session["username"] == null) { Response.Redirect("login.aspx"); } Response.Buffer = true; Response.ExpiresAbsolute = DateTime.Now.AddDays(-1d); Response.Expires = -1500; Response.CacheControl = "no-cache";
:)Deepak Smile a Lots,Its Costs Nothing
-
these code may help u to remove page from cache. these code r write into Page Load event
if (Session["username"] == null) { Response.Redirect("login.aspx"); } Response.Buffer = true; Response.ExpiresAbsolute = DateTime.Now.AddDays(-1d); Response.Expires = -1500; Response.CacheControl = "no-cache";
:)Deepak Smile a Lots,Its Costs Nothing
Thanx Deepak But I was looking for page directive to disable caching.
-
Thanx Deepak But I was looking for page directive to disable caching.
-
Page.Response.Cache.SetCacheability(HttpCacheability.NoCache) ? you should explain what behaviour you would like to achieve... Pilo
Thanx for that