OutputCache problem

Reply Forum
Forum postcuarti @ 2009-01-30 20:17:19
ReplyReply to
hi, im trying to clean the cache everytime i come back from another page, i have the
the first page has

<%@ OutputCache Duration="1" VaryByParam="none"%>

on my aspx, and on the aspx.cs i have:
Session["user"] = "whatever" (thats the session variable that i want to pass) then in the second page i have the
if (Session["user"].ToString() == "whatever")
{
LB.Text = Session["user"].ToString();
}
else
{
Response.Redirect("page1.aspx");
}
that works fine, but if on the second page i made click on the backward botton of the browser(<-), then i made click on the forward botton(->;), it doesnt clean the cache, it should not be able to enter the 2nd page :(

plz help i need this to try to manage my login sessions, i hope that i explained my problem well

thx;


Forum postWebmaster @ 2009-02-09 10:51:55
ReplyReply to
I think the problem occurs because the page is being reloaded from the browser cache, when you use the back and forward buttons. Try reloading the page, perhaps even a force-reload, using the Ctrl+F5 shortcut (works in IE and Mozilla) :)











© net-tutorials.com 2006 - 2012

MailContact net-tutorials.com