fix parse error at index.php under PHP 5.3

This commit is contained in:
printempw 2016-12-17 20:48:13 +08:00
parent 55f8c87b92
commit 372be47ac8
4 changed files with 12 additions and 12 deletions

View File

@ -305,11 +305,6 @@ if (! function_exists('runtime_check')) {
function runtime_check(array $requirements)
{
// check php version
if (version_compare(PHP_VERSION, $requirements['php'], '<')) {
exit("[Error] Blessing Skin Server needs PHP version >= {$requirements['php']}, you are now using ".PHP_VERSION);
}
foreach ($requirements['extensions'] as $extension) {
if (!extension_loaded($extension)) {
exit("[Error] You have not installed the $extension extension");

View File

@ -2,8 +2,6 @@
define('LARAVEL_START', microtime(true));
ini_set('display_errors', 'on');
/*
|--------------------------------------------------------------------------
| Register The Composer Auto Loader

View File

@ -2,7 +2,7 @@
* @Author: prpr
* @Date: 2016-07-21 13:38:26
* @Last Modified by: printempw
* @Last Modified time: 2016-12-10 20:22:13
* @Last Modified time: 2016-12-17 20:36:36
*/
var gulp = require('gulp'),
@ -100,6 +100,7 @@ gulp.task('zip', function() {
del([
'storage/logs/*',
'storage/debugbar/*',
'storage/update_cache/*',
'storage/yaml-translation/*',
'storage/framework/cache/*',
'storage/framework/sessions/*',

View File

@ -7,13 +7,19 @@
* @author printempw <h@prinzeugen.net>
*/
@ini_set('display_errors', 'on');
// check PHP version
if (version_compare(PHP_VERSION, '5.5.9', '<')) {
exit('[Error] Blessing Skin Server needs PHP version >= 5.5.9, you are now using '.PHP_VERSION);
}
require __DIR__.'/bootstrap/autoload.php';
// check the runtime environment
runtime_check([
'php' => '5.5.9',
'extensions' => ['pdo_mysql', 'openssl', 'gd']
]);
runtime_check(array(
'extensions' => array('pdo_mysql', 'openssl', 'gd')
));
// handle the request
require __DIR__.'/bootstrap/handler.php';