Re: refresh page (might be 0t)

From: Date: Sun, 08 Feb 2004 04:50:24 +0000
Subject: Re: refresh page (might be 0t)
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-177122@lists.php.net to get a copy of this message
On Sat, 2004-02-07 at 23:03, Ryan A wrote: > Heres what I am doing: > I give the client a control panel where he can add,edit and delete accounts, > after each of the actions I have a link back to > the index page of the contol panel...problem is, unless he presses the > refresh button it shows him the same cached content. > How do i force the browser to display the new updated accounts after and > edit or the new list of accounts after a delete? It sounds like you may want to set the page to not be cached. Here's what I use to prevent pages from being cached: function noCacheHeaders() { header('Expires: Tue, 1 Jan 1980 12:00:00 GMT'); header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); header('Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0, no-transform'); header('Pragma: no-cache'); } This should prevent proxies, browsers, etc from caching your pages. -- Adam Bregenzer adam@bregenzer.net http://adam.bregenzer.net/

« previous php.general (#177122) next »