summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrobin <robin@208e9e7b-5314-0410-a742-e7e81cd9613c>2008-03-27 12:13:55 +0000
committerrobin <robin@208e9e7b-5314-0410-a742-e7e81cd9613c>2008-03-27 12:13:55 +0000
commit0ad9227ecae9cc3383c63030654829dc24d7c73a (patch)
tree6c02044307a9b7f0aecab505a5b87696df1d66f0
parent343dfc449d5d663d740fab30bfcb8deedd1f13b3 (diff)
Fix php version check in installer, closes #1484925.
git-svn-id: https://svn.roundcube.net/trunk@1220 208e9e7b-5314-0410-a742-e7e81cd9613c
-rw-r--r--roundcubemail/installer/check.php7
1 files changed, 4 insertions, 3 deletions
diff --git a/roundcubemail/installer/check.php b/roundcubemail/installer/check.php
index c60244e94..7ca982f2d 100644
--- a/roundcubemail/installer/check.php
+++ b/roundcubemail/installer/check.php
@@ -37,10 +37,11 @@ echo '<input type="hidden" name="_step" value="' . ($RCI->configured ? 3 : 2) .
<h3>Checking PHP version</h3>
<?php
-if (phpversion() > 4.3) {
- $RCI->pass('Version', 'PHP ' . phpversion() . ' detected');
+define('MIN_PHP_VERSION', '5.2.0');
+if (version_compare(PHP_VERSION, MIN_PHP_VERSION, '>=')) {
+ $RCI->pass('Version', 'PHP ' . PHP_VERSION . ' detected');
} else {
- $RCI->fail('Version', 'PHP Version 4.3.1 or greater is required');
+ $RCI->fail('Version', 'PHP Version ' . MIN_PHP_VERSION . ' or greater is required ' . PHP_VERSION . ' detected');
}
?>