23# T32219 : can not use pathinfo() on URLs since slashes do not match
29foreach ( array_filter( explode(
'/', $_SERVER[
'PHP_SELF'] ) ) as $part ) {
30 if ( !preg_match(
'/\.(php)$/', $part,
$matches ) ) {
37# Check to see if the installer is running
38if ( !function_exists(
'session_name' ) ) {
42 session_name(
'mw_installer_session' );
44 $oldReporting = error_reporting( E_ALL & ~E_NOTICE );
46 error_reporting( $oldReporting );
52# Render error page if no LocalSettings file can be found
57 'version' => ( defined(
'MW_VERSION' ) ?
MW_VERSION :
'VERSION' ),
59 'localSettingsExists' => file_exists( MW_CONFIG_FILE ),
63}
catch ( Exception $e ) {
64 echo
'Error: ' . htmlspecialchars( $e->getMessage() );
const MW_VERSION
The running version of MediaWiki.
wfIniGetBool( $setting)
Safety wrapper around ini_get() for boolean settings.