summaryrefslogtreecommitdiffhomepage
path: root/test/php/404/index.php
diff options
context:
space:
mode:
authorAndrey Zelenkov <zelenkov@nginx.com>2019-03-01 18:58:16 +0300
committerAndrey Zelenkov <zelenkov@nginx.com>2019-03-01 18:58:16 +0300
commitae36276cfc9ce2ecfb09be4d4c16e0b1b81901ee (patch)
treeb01baed75edea6ab09e1711c55d3f41c71c4dd59 /test/php/404/index.php
parent557a792b33f0cc2fd0bc36c164b6d46a564712ea (diff)
downloadunit-ae36276cfc9ce2ecfb09be4d4c16e0b1b81901ee.tar.gz
unit-ae36276cfc9ce2ecfb09be4d4c16e0b1b81901ee.tar.bz2
Tests: made tests compatible with PHP 5.3.
Diffstat (limited to '')
-rw-r--r--test/php/404/index.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/test/php/404/index.php b/test/php/404/index.php
index 92afdf19..561dbec2 100644
--- a/test/php/404/index.php
+++ b/test/php/404/index.php
@@ -1,4 +1,10 @@
<?php
-http_response_code(404);
+if (!function_exists('http_response_code')) {
+ header('Temporary-Header: True', true, 404);
+ header_remove('Temporary-Header');
+} else {
+ http_response_code(404);
+}
+
include('404.html');
?>