From f7df6c4c4d2e132997f5ed248c1d3dab2f575be5 Mon Sep 17 00:00:00 2001 From: till Date: Tue, 14 Jul 2009 15:05:57 +0000 Subject: * added check for date.timezone --- installer/check.php | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) (limited to 'installer/check.php') diff --git a/installer/check.php b/installer/check.php index 848131e51..392ea49dc 100644 --- a/installer/check.php +++ b/installer/check.php @@ -16,7 +16,7 @@ $supported_dbs = array('MySQL' => 'mysql', 'MySQLi' => 'mysqli', $ini_checks = array('file_uploads' => 1, 'session.auto_start' => 0, 'zend.ze1_compatibility_mode' => 0, 'mbstring.func_overload' => 0, - 'suhosin.session.encrypt' => 0); + 'suhosin.session.encrypt' => 0, 'date.timezone' => '-NOTEMPTY-'); $source_urls = array( 'Sockets' => 'http://www.php.net/manual/en/ref.sockets.php', @@ -131,10 +131,27 @@ foreach ($required_libs as $classname => $file) { foreach ($ini_checks as $var => $val) { $status = ini_get($var); + if ($val === '-NOTEMPTY-') { + if (empty($status)) { + $RCI->fail($var, "cannot be empty and needs to be set"); + } else { + switch ($var) { + case 'date.timezone': + if (date_default_timezone_get() === false) { + $RCI->fail($var, "is '$status', but the settings is wrong"); + echo '
'; + continue; + } + break; + } + $RCI->pass($var); + } + echo '
'; + continue; + } if ($status == $val) { $RCI->pass($var); - } - else { + } else { $RCI->fail($var, "is '$status', should be '$val'"); } echo '
'; -- cgit v1.2.3