CC-5584: Quick PHP version check (5.4+)

* Thanks to John Chewter for connecting the dots on this one!
This commit is contained in:
Albert Santoni 2013-11-28 16:04:56 -05:00
parent 5b2b306eb5
commit bf5e995547
1 changed files with 8 additions and 0 deletions

View File

@ -12,6 +12,14 @@ require_once(__DIR__.'/airtime-constants.php');
// The only way we get here is if we are doing a new install or a reinstall.
// -------------------------------------------------------------------------
if (PHP_VERSION_ID < 50400) //PHP 5.4
{
echo("ERROR: Your PHP version is too old!\nAirtime requires PHP 5.4 or greater.\n");
exit(1);
}
die(0);
$iniExists = file_exists("/etc/airtime/airtime.conf");
if ($iniExists) {
//reinstall, Will ask if we should rewrite config files.