X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/timetracker.git/blobdiff_plain/32acd0caf0385a9fb7014af70d1a0ad438191dd7..2a76f4497cf158ca7e81b6b3ae1998ea28e45044:/dbinstall.php diff --git a/dbinstall.php b/dbinstall.php index 74d566cc..e32df0ed 100644 --- a/dbinstall.php +++ b/dbinstall.php @@ -92,6 +92,11 @@ if ($request->isGet()) { echo('Error: PHP version is not high enough: '.phpversion().'. Required: '.$required_version.'.
'); } + // Check if PHP session path is writeable. + if (!is_writable(session_save_path())) { + echo('Error: PHP session path '.session_save_path().' is not writable.
'); + } + // Depending on DSN, require either mysqli or mysql extensions. if (strrpos(DSN, 'mysqli://', -strlen(DSN)) !== FALSE) { if (extension_loaded('mysqli')) { @@ -131,6 +136,11 @@ if ($request->isGet()) { } } + // Check is libxml is enabled (which is a PHP default). + if (!function_exists('libxml_clear_errors')) { + echo('Error: libxml is not enabled. It is required for import group operation (to parse XML).
'); + } + // Check database access. require_once('MDB2.php'); $conn = MDB2::connect(DSN); @@ -1044,6 +1054,8 @@ if ($_POST) { ttExecute("UPDATE `tt_site_config` SET param_value = '1.18.34', modified = now() where param_name = 'version_db' and param_value = '1.18.26'"); ttExecute("update `tt_users` u inner join `tt_site_config` sc on (sc.param_name = 'version_db' and sc.param_value = '1.18.34') set u.quota_percent = 100.00 where u.quota_percent is null"); ttExecute("UPDATE `tt_site_config` SET param_value = '1.18.36', modified = now() where param_name = 'version_db' and param_value = '1.18.34'"); + ttExecute("update `tt_users` u inner join `tt_site_config` sc on (sc.param_name = 'version_db' and sc.param_value = '1.18.36') set u.quota_percent = 100.00 where u.quota_percent is null"); + ttExecute("ALTER TABLE `tt_users` modify `quota_percent` float(6,2) NOT NULL default '100.00'"); } if ($_POST["cleanup"]) {