Commit 61296ed7 authored by Frank Karlitschek's avatar Frank Karlitschek Committed by Vincent Petry
Browse files

lower required php version to 5.3.3

parent b83e8914
...@@ -437,9 +437,9 @@ class OC_Util { ...@@ -437,9 +437,9 @@ class OC_Util {
); );
$webServerRestart = true; $webServerRestart = true;
} }
if(version_compare(phpversion(), '5.3.8', '<')) { if(version_compare(phpversion(), '5.3.3', '<')) {
$errors[] = array( $errors[] = array(
'error'=>'PHP 5.3.8 or higher is required.', 'error'=>'PHP 5.3.3 or higher is required.',
'hint'=>'Please ask your server administrator to update PHP to the latest version.' 'hint'=>'Please ask your server administrator to update PHP to the latest version.'
.' Your PHP version is no longer supported by ownCloud and the PHP community.' .' Your PHP version is no longer supported by ownCloud and the PHP community.'
); );
...@@ -874,6 +874,14 @@ class OC_Util { ...@@ -874,6 +874,14 @@ class OC_Util {
return function_exists('finfo_open'); return function_exists('finfo_open');
} }
/**
* @brief Check if a PHP version older then 5.3.8 is installed.
* @return bool
*/
public static function isPHPoutdated() {
return version_compare(phpversion(), '5.3.8', '<');
}
/** /**
* @brief Check if the ownCloud server can connect to the internet * @brief Check if the ownCloud server can connect to the internet
* @return bool * @return bool
......
...@@ -28,6 +28,7 @@ $tmpl->assign('internetconnectionworking', OC_Util::isInternetConnectionEnabled( ...@@ -28,6 +28,7 @@ $tmpl->assign('internetconnectionworking', OC_Util::isInternetConnectionEnabled(
$tmpl->assign('isLocaleWorking', OC_Util::isSetLocaleWorking()); $tmpl->assign('isLocaleWorking', OC_Util::isSetLocaleWorking());
$tmpl->assign('isWebDavWorking', OC_Util::isWebDAVWorking()); $tmpl->assign('isWebDavWorking', OC_Util::isWebDAVWorking());
$tmpl->assign('has_fileinfo', OC_Util::fileInfoLoaded()); $tmpl->assign('has_fileinfo', OC_Util::fileInfoLoaded());
$tmpl->assign('old_php', OC_Util::isPHPoutdated());
$tmpl->assign('backgroundjobs_mode', OC_Appconfig::getValue('core', 'backgroundjobs_mode', 'ajax')); $tmpl->assign('backgroundjobs_mode', OC_Appconfig::getValue('core', 'backgroundjobs_mode', 'ajax'));
$tmpl->assign('shareAPIEnabled', OC_Appconfig::getValue('core', 'shareapi_enabled', 'yes')); $tmpl->assign('shareAPIEnabled', OC_Appconfig::getValue('core', 'shareapi_enabled', 'yes'));
......
...@@ -72,6 +72,20 @@ if (!$_['has_fileinfo']) { ...@@ -72,6 +72,20 @@ if (!$_['has_fileinfo']) {
<?php <?php
} }
// is PHP at least at 5.3.8?
if ($_['old_php']) {
?>
<fieldset class="personalblock">
<h2><?php p($l->t('Your PHP version is outdated'));?></h2>
<span class="connectionwarning">
<?php p($l->t('Your PHP version is outdated. We strongly recommend to update to 5.3.8 or newer because older versions are known to be broken. It is possible that this installation is not working correctly.')); ?>
</span>
</fieldset>
<?php
}
// is locale working ? // is locale working ?
if (!$_['isLocaleWorking']) { if (!$_['isLocaleWorking']) {
?> ?>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment