aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB
diff options
context:
space:
mode:
authorHenry Sudhof <kellanved@phpbb.com>2007-12-19 17:23:14 +0000
committerHenry Sudhof <kellanved@phpbb.com>2007-12-19 17:23:14 +0000
commitab9465a90e6ebb9c485d180431d297ba14af4884 (patch)
treeba0b18e02da2ca9a454a72c17803fccc7e91800b /phpBB
parent3ca0a7cb7616860ac0941f7d3b302f7b318a7fb6 (diff)
downloadforums-ab9465a90e6ebb9c485d180431d297ba14af4884.tar
forums-ab9465a90e6ebb9c485d180431d297ba14af4884.tar.gz
forums-ab9465a90e6ebb9c485d180431d297ba14af4884.tar.bz2
forums-ab9465a90e6ebb9c485d180431d297ba14af4884.tar.xz
forums-ab9465a90e6ebb9c485d180431d297ba14af4884.zip
Hopefully fixes avatar caching for CGI installs.
git-svn-id: file:///svn/phpbb/trunk@8281 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB')
-rw-r--r--phpBB/docs/CHANGELOG.html1
-rw-r--r--phpBB/download/file.php8
2 files changed, 9 insertions, 0 deletions
diff --git a/phpBB/docs/CHANGELOG.html b/phpBB/docs/CHANGELOG.html
index 12801b1fc8..00f54c0abf 100644
--- a/phpBB/docs/CHANGELOG.html
+++ b/phpBB/docs/CHANGELOG.html
@@ -85,6 +85,7 @@
<ul>
<li>[Change] Validate birthdays (Bug #15004)</li>
+ <li>[Fix] Allow correct avatar caching for CGI installations. (thanks wildbill)</li>
</ul>
<a name="v30rc8"></a><h3>1.i. Changes since 3.0.RC8</h3>
diff --git a/phpBB/download/file.php b/phpBB/download/file.php
index c3ba3820f9..9bf16ce0dc 100644
--- a/phpBB/download/file.php
+++ b/phpBB/download/file.php
@@ -68,6 +68,14 @@ if (isset($_GET['avatar']))
if ($last_load !== false && $last_load <= $stamp)
{
header('Not Modified', true, 304);
+ if (@php_sapi_name() == 'CGI')
+ {
+ header('Status: 304 Not Modified', true, 304);
+ }
+ else
+ {
+ header('HTTP/1.0 304 Not Modified', true, 304);
+ }
// seems that we need those too ... browsers
header('Pragma: public');
header('Expires: ' . gmdate('D, d M Y H:i:s \G\M\T', time() + 31536000));