I've set my aspx page to expire immediately using the management console,
HTTP headers tab. Considering this scenario:
a user visits the aspx page in question, then moves to another page, then
hits the Back button to return to the page in question. At that point,
shouldn't the Page_Load event fire for the page since it was set to expire
immediately?
Thanks
Timo

Re: HTTP header immediate expiration and Page_Load in asp.net by Joerg

Joerg
Sat May 28 05:02:28 CDT 2005

Timo wrote:

> I've set my aspx page to expire immediately using the management
> console, HTTP headers tab. Considering this scenario:
> a user visits the aspx page in question, then moves to another page,
> then hits the Back button to return to the page in question. At that
> point, shouldn't the Page_Load event fire for the page since it was
> set to expire immediately?

No. Back button behaviour is unfortunately browser-specific. Many
browsers even adopt their behaviour depending on what Cache-Control
header they receive, or whether the underlying connection is secure or
not.

In addition to Expires (which isn't really that useful anyway), try
Cache-Control: no-cache or Cache-Control: max-age=0.

Cheers,
--
http://www.joergjooss.de
mailto:news-reply@joergjooss.de

Re: HTTP header immediate expiration and Page_Load in asp.net by Timo

Timo
Sat May 28 07:50:43 CDT 2005

Thanks, Joerg. Setting No-cache in code-behind has the desired effect, as
you suggested.
Timo


"Joerg Jooss" <news-reply@joergjooss.de> wrote in message
news:xn0e2saxd1q492002@msnews.microsoft.com...

> Back button behaviour is unfortunately browser-specific. Many
> browsers even adopt their behaviour depending on what Cache-Control
> header they receive, or whether the underlying connection is secure or
> not.
>
> In addition to Expires (which isn't really that useful anyway), try
> Cache-Control: no-cache or Cache-Control: max-age=0.