[Catalyst] Caching problem?
Toby Corkindale
tjc at wintrmute.net
Wed Jan 11 17:55:41 CET 2006
On Wed, Jan 11, 2006 at 08:47:54AM -0800, Dr. Jennifer Nussbaum wrote:
> I have a Catalyst application that does the usual database thingies. I
> just learned that when database info changes, the pages arent getting
> updated because theyre being cached, so if someone goes to
> www.mysite.com/catalog/view/242, they get the same content even if
> things have changed. Users can "reload" in the browser and get the
> right content.
>
> Whats the easiest way that this doesnt happen?
You can set the response headers:
Cache-control: no-cache
Pragma: no-cache
$c->response->headers->header( ’Cache-control’ => 'no-cache' );
$c->response->headers->header( ’Pragma’ => 'no-cache' );
tjc
--
Turning and turning in the widening gyre/The falcon cannot hear the falconer;
Things fall apart, the centre cannot hold/Mere anarchy is loosed upon the world
(gpg --keyserver www.co.uk.pgp.net --recv-key B1CCF88E)
More information about the Catalyst
mailing list