[11511] in www-talk@info.cern.ch

home help back first fref pref prev next nref lref last post

Re: Enforce reloading of page when using the back-button

daemon@ATHENA.MIT.EDU (=?iso-8859-1?Q?Christian_B=F8hn?=)
Wed Mar 8 13:26:28 2000

Message-Id: <00ff01bf892a$f7a09030$5d074382@bohns>
From: =?iso-8859-1?Q?Christian_B=F8hn?= <chrb@online.no>
To: "HUI XIONG" <xionghui@comp.nus.edu.sg>, <www-talk@w3.org>
Date: Wed, 8 Mar 2000 19:20:05 +0100
Mime-Version: 1.0
Content-Type: text/plain;
	charset="iso-8859-1"
Resent-From: www-talk@w3.org
Content-Transfer-Encoding: quoted-printable

Hi,

I have tried those headers, but without luck. I tried them again after
clearing my browser cache, still not working. I tried your site, and it
worked! The page was reloaded when hitting the back-button. I too agree t=
hat
this shouldn't be used normally, but in some cases, especially regarding
security, this would be wanted. As the headers didn't work with me, what
more does your cache-busting technique do?
Thanks!

Christian

> You should use the following three headers together:
>
> Cache-Control: no-cache
> Pragma: no-cache
> Expires: 0
>
> In this way, you can get what you want. As for the problem you
> mentioned, you
> may need to clean up all the pages in the browser cache before you do
> any test.
> I made a test Web site, you may see the effect.
> http://137.132.96.195/vagent
>
> Note: I use Cache-busting techniques only for research purpose. I do
> agree with
> Mr. Dan Connolly. It's not good to use this kind of techniques for Web
> design.
>
> Hui Xiong
>
>
> Christian B=F8hn wrote:
>
> > Hi,
> >
> > Is there a way to make the browser reload a page from server when the
> > back-button is used. I have tried the "Pragma", "Cache-control" and
> > "Expires" headers, but it doesn't prevent the browser from loading th=
e
> page
> > from cache when the back-button is used. (for example IE5 does load i=
t
> from
> > cache). I would like to avoid this in some cases, and have the browse=
r
> to
> > send a new request so the server could determine if the user is still
> logged
> > in (ie hasn't clicked any logout button on a page), and if not, show =
a
> not
> > logged in page, rather than the previos content of the page.
> >
> > Is this possible? Thanks a lot in advance!
> >
> > Christian
>
>
>
>
>


home help back first fref pref prev next nref lref last post