X-Git-Url: http://git.cyclocoop.org/%28?a=blobdiff_plain;f=mw-config%2Findex.php;h=a6cebc3951645902ccd11ceff354dcfe9be0429b;hb=d06af57a3139ca49001943621d3187e203681351;hp=56c1308956d109967e67b6fd6d1d0312a885fcdf;hpb=9a88ac683615bfb2e828ff37b355ee62be36421f;p=lhc%2Fweb%2Fwiklou.git diff --git a/mw-config/index.php b/mw-config/index.php index 56c1308956..a6cebc3951 100644 --- a/mw-config/index.php +++ b/mw-config/index.php @@ -20,6 +20,13 @@ * @file */ +// Bail if PHP is too low +if ( !function_exists( 'version_compare' ) || version_compare( PHP_VERSION, '5.3.2' ) < 0 ) { + // We need to use dirname( __FILE__ ) here cause __DIR__ is PHP5.3+ + require dirname( dirname( __FILE__ ) ) . '/includes/PHPVersionError.php'; + wfPHPVersionError( 'mw-config/index.php' ); +} + define( 'MW_CONFIG_CALLBACK', 'Installer::overrideConfig' ); define( 'MEDIAWIKI_INSTALL', true ); @@ -37,7 +44,7 @@ function wfInstallerMain() { if ( !$installer->startSession() ) { - if( $installer->request->getVal( "css" ) ) { + if ( $installer->request->getVal( "css" ) ) { // Do not display errors on css pages $installer->outputCss(); exit;