He ain't ugly, he's my brother.

git-svn-id: https://develop.svn.wordpress.org/trunk@2584 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Matt Mullenweg 2005-05-05 23:05:51 +00:00
parent e749e54a6b
commit ba9eb22b33
1 changed files with 13 additions and 14 deletions

View File

@ -133,22 +133,21 @@ if ( !empty($error) && '404' == $error ) {
if (isset($_SERVER['HTTP_IF_NONE_MATCH'])) $client_etag = stripslashes($_SERVER['HTTP_IF_NONE_MATCH']);
else $client_etag = false;
if ( $client_last_modified && $client_etag ) {
if ( (strtotime($client_last_modified) >= strtotime($wp_last_modified)) || ($client_etag == $wp_etag) ) {
if ( ($client_last_modified && $client_etag) ?
((strtotime($client_last_modified) >= strtotime($wp_last_modified)) && ($client_etag == $wp_etag)) :
((strtotime($client_last_modified) >= strtotime($wp_last_modified)) || ($client_etag == $wp_etag)) ) {
if ( preg_match('/cgi/',php_sapi_name()) ) {
header('Status: 304 Not Modified');
echo "\r\n\r\n";
exit;
} else {
if ( version_compare(phpversion(), '4.3.0', '>=') ) {
if ( version_compare(phpversion(), '4.3.0', '>=') )
header('Not Modified', TRUE, 304);
} else {
else
header('HTTP/1.x 304 Not Modified');
}
exit;
}
}
}
}
$use_gzipcompression = get_settings('gzipcompression');