public/js/kcfinder/lib/helper_httpCache.php
static function checkMTime($mtime, $sendHeaders=null) {
        header("Last-Modified: " . gmdate("D, d M Y H:i:s", $mtime) . " GMT");

        $headers = function_exists("getallheaders")
            ? getallheaders()
            : (function_exists("apache_request_headers")
                ? apache_request_headers()
                : false);

        if (is_array($headers) && isset($headers['If-Modified-Since'])) {
            $client_mtime = explode(';', $headers['If-Modified-Since']);
            $client_mtime = @strtotime($client_mtime[0]);
            if ($client_mtime >= $mtime) {
                header('HTTP/1.1 304 Not Modified');
                if (is_array($sendHeaders) && count($sendHeaders))
                    foreach ($sendHeaders as $header)
                        header($header);
                elseif ($sendHeaders !== null)
                    header($sendHeaders);
                die;
            }
        }
    }
static function checkMTime($mtime, $sendHeaders=null) {
        header("Last-Modified: " . gmdate("D, d M Y H:i:s", $mtime) . " GMT");

        $headers = function_exists("getallheaders")
            ? getallheaders()
            : (function_exists("apache_request_headers")
                ? apache_request_headers()
                : false);

        if (is_array($headers) && isset($headers['If-Modified-Since'])) {
            $client_mtime = explode(';', $headers['If-Modified-Since']);
            $client_mtime = @strtotime($client_mtime[0]);
            if ($client_mtime >= $mtime) {
                header('HTTP/1.1 304 Not Modified');
                if (is_array($sendHeaders) && count($sendHeaders))
                    foreach ($sendHeaders as $header)
                        header($header);
                elseif ($sendHeaders !== null)
                    header($sendHeaders);
                die;
            }
        }
    }
Check if given modification time is newer than client-side one. If not,
the method will tell the client to get the content from its own cache.
Afterwards the script process will be terminated. This feature requires
the PHP to be configured as Apache module.
@param integer $mtime
@param mixed $sendHeaders