rendered paste body<?php header("Content-type: text/xml"); $cache = "savage2.s2games.com.html"; $cache_secs = 2*60; // if the cache isn't there, make it if(!file_exists($cache)) { $site = file_get_contents("http://savage2.s2games.com/"); file_put_contents($cache, $site); unset($site); } $props = stat($cache); // if the cache is too old, purge and renew if(($props[9] + $cache_secs) <= time()) { unlink($cache); $site = file_get_contents("http://savage2.s2games.com/"); file_put_contents($cache, $site); unset($site); } $site = file_get_contents($cache);