function doConditionalGet($timestamp) { global $SERVER; // A PHP implementation of conditional get, see // http://fishbowl.pastiche.org/archives/001132.html // Editiert, übersetzt und berichtigt von Jan Piotrowski // header generieren $last_modified = gmdate("D, d M Y H:i:s", $timestamp).' GMT'; $etag = md5($last_modified); // header senden header("Last-Modified: ".$last_modified); header("ETag: \"".$etag."\""); // pruefung: hat der client die notwendigen header uebermittelt $if_modified_since = isset($_SERVER['HTTP_IF_MODIFIED_SINCE']) ? stripslashes($_SERVER['HTTP_IF_MODIFIED_SINCE']) : false; $if_none_match = isset($_SERVER['HTTP_IF_NONE_MATCH']) ? stripslashes($_SERVER['HTTP_IF_NONE_MATCH']) : false; if (!$if_modified_since && !$if_none_match) { return; } // mind. ein header ist da - ueberpruefen if ($if_none_match && $if_none_match != $etag) { return; // etag ist vorhanden, passt aber nicht } if ($if_modified_since && $if_modified_since != $last_modified) { return; // if-modified-since ist vorhanden, passt aber nicht } // keine verändertung seit dem letzten request - 304 und exit header('HTTP/1.0 304 Not Modified'); exit; } doConditionalGet(mktime("09","10",date("s"),date("m"),date("d"),date("Y"))); header("Cache-Control: must-revalidate, proxy-revalidate, public"); header("Accept-Ranges: bytes"); # header("Content-Length: 4128"); # header("HTTP/1.1 200 OK"); # header("Pragma: no-cache"); # header("Cache-Control: no-store, no-cache, must-revalidate, post-check=0,pre-check=0"); # header("Last-Modified: ".date("D, d M Y ")." 09:10:23 GMT"); # header("Expires: Sun, 19 Dec 1982 07:30:03 GMT"); include("inc/config.inc.php"); include("inc/html.php"); $send_falsh = "c_id=$_GET[c_id]&lang=$_GET[lang]"; if(!$_GET[open]) $_GET[open]=0; ?>