X-Git-Url: https://git.cyclocoop.org/admin/?a=blobdiff_plain;f=index.php;h=5e5f47c5379d1d950cc9b258b4b6c162a67e90e6;hb=eeb16a279ebe7154895b09ab977865083f3437f8;hp=4fed9b8f108441db938836cc58651e907d782693;hpb=abea84bccd0830423f7bf74279d1a44660e52a59;p=lhc%2Fweb%2Fwiklou.git diff --git a/index.php b/index.php index 4fed9b8f10..5e5f47c537 100644 --- a/index.php +++ b/index.php @@ -64,9 +64,17 @@ ENDL; # Initialise common code. This gives us access to GlobalFunctions, the AutoLoader, and # the globals $wgRequest, $wgOut, $wgUser, $wgLang and $wgContLang, amongst others; it # does *not* load $wgTitle -require ( dirname( __FILE__ ) . '/includes/WebStart.php' ); +if ( isset( $_SERVER['MW_COMPILED'] ) ) { + require ( 'phase3/includes/WebStart.php' ); +} else { + require ( dirname( __FILE__ ) . '/includes/WebStart.php' ); +} -wfIndexMain(); +try { + wfIndexMain(); +} catch ( Exception $e ) { + MWExceptionHandler::handle( $e ); +} function wfIndexMain() { global $wgRequest, $wgShowHostnames, $mediaWiki, $wgTitle, $wgUseAjax, $wgUseFileCache; @@ -88,6 +96,8 @@ function wfIndexMain() { } else { echo "Waiting for a database server: $lag seconds lagged\n"; } + wfProfileOut( 'index.php-setup' ); + wfProfileOut( 'index.php' ); return; } }