23# T32219 : can not use pathinfo() on URLs since slashes do not match
26foreach ( array_filter( explode(
'/', $_SERVER[
'PHP_SELF'] ) ) as $part ) {
27 if ( !preg_match(
'/\.(php)$/', $part,
$matches ) ) {
34# Check to see if the installer is running
35if ( !function_exists(
'session_name' ) ) {
39 session_name(
'mw_installer_session' );
41 $oldReporting = error_reporting( E_ALL & ~E_NOTICE );
43 error_reporting( $oldReporting );
49# Render error page if no LocalSettings file can be found
57 'localSettingsExists' => file_exists( MW_CONFIG_FILE ),
61}
catch ( Exception
$e ) {
62 echo
'Error: ' . htmlspecialchars(
$e->getMessage() );
$wgVersion
MediaWiki version number.
wfIniGetBool( $setting)
Safety wrapper around ini_get() for boolean settings.
returning false will NOT prevent logging $e