Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

MINOR make cache header clearer (from r100732)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@105632 467b73ca-7a2a-4603-9d3b-597d59a354a9
  • Loading branch information...
commit d87964f359ae9734c7f47bcd4faf60e498a91734 1 parent eed941d
@chillu chillu authored
Showing with 3 additions and 3 deletions.
  1. +3 −3 static-main.php
View
6 static-main.php
@@ -47,14 +47,14 @@
$file = preg_replace('/[^a-zA-Z0-9]/si', '_', $file);
if (file_exists('../cache/'.$cacheDir.$file.'.html')) {
- header('X-cache: hit at '.@date('r'));
+ header('X-SilverStripe-Cache: hit at '.@date('r'));
echo file_get_contents('../cache/'.$cacheDir.$file.'.html');
} elseif (file_exists('../cache/'.$cacheDir.$file.'.php')) {
- header('X-cache: hit at '.@date('r'));
+ header('X-SilverStripe-Cache: hit at '.@date('r'));
include_once '../cache/'.$cacheDir.$file.'.php';
if ($cacheDebug) echo "<h1>File was cached</h1>";
} else {
- header('X-cache: miss at '.@date('r') . ' on ' . $cacheDir . $file);
+ header('X-SilverStripe-Cache: miss at '.@date('r') . ' on ' . $cacheDir . $file);
// No cache hit... fallback!!!
include 'main.php';
if ($cacheDebug) echo "<h1>File was !NOT! cached</h1>";
Please sign in to comment.
Something went wrong with that request. Please try again.