Support Forums

Development Forum

prevent visitors pages from being cached


You must be signed-in to post.

AuthorSubject
  Page: 1
joshua_howell

Avatar for joshua_howell
Subject: prevent visitors pages from being cachedQuote this post in your reply
I am having issues with cached pages displaying old data so i would like to prevent visitors browsers from caching pages from "server side".

Apparently the code below should do this, can anyone forsee any problems with using this code and is there asingle file i can add this to so every single ATutor page will inherit it?


<?php
header
(\"Cache-Control: no-cache, must-revalidate"); // HTTP/1.1
$today = date("D, d M Y H:i:s T"); // todays date
header("Expires: ". 
$today.""); // Date in the past
?>


Posted: 2009-08-17 20:43:45
 Page: 1

You must be signed-in to post.