From 7479592c81e671d18dc70afbd0ed2514271fe164 Mon Sep 17 00:00:00 2001 From: Henry Sudhof Date: Tue, 14 Apr 2009 13:59:12 +0000 Subject: [PATCH] Some changes to the SAPI detection. The weird fact that it doesn't work without remains. git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@9448 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/download/file.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/phpBB/download/file.php b/phpBB/download/file.php index f71afb670e..f7cf0d09e2 100644 --- a/phpBB/download/file.php +++ b/phpBB/download/file.php @@ -670,8 +670,9 @@ function set_modified_headers($stamp, $browser) { if ($last_load !== false && $last_load <= $stamp) { - if (@php_sapi_name() === 'CGI') + if (substr(strtolower(@php_sapi_name()),0,3) === 'cgi') { + // in theory, we shouldn't need that due to php doing it. Reality offers a differing opinion, though header('Status: 304 Not Modified', true, 304); } else