From: Trevor Parscal Date: Fri, 10 Sep 2010 21:51:25 +0000 (+0000) Subject: Applied patch for bug #25044 by Niklas Laxström -- THANKS! X-Git-Tag: 1.31.0-rc.0~35028 X-Git-Url: http://git.cyclocoop.org/%28?a=commitdiff_plain;h=ce8f81837c17729d9d6794f3097ee81458ac9ea3;p=lhc%2Fweb%2Fwiklou.git Applied patch for bug #25044 by Niklas Laxström -- THANKS! --- diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php index 9272c7b39c..fab31a8e8d 100644 --- a/includes/DefaultSettings.php +++ b/includes/DefaultSettings.php @@ -142,6 +142,12 @@ $wgScript = false; $wgRedirectScript = false; ///< defaults to /**@}*/ +/** + * The URL path to load.php. + * + * Defaults to "{$wgScriptPath}/load{$wgScriptExtension}". + */ +$wgLoadScript = false; /************************************************************************//** * @name URLs and file paths diff --git a/includes/OutputPage.php b/includes/OutputPage.php index 0d8088857c..93f245fb4b 100644 --- a/includes/OutputPage.php +++ b/includes/OutputPage.php @@ -2281,7 +2281,7 @@ class OutputPage { } static function makeResourceLoaderLink( $skin, $modules, $only ) { - global $wgUser, $wgLang, $wgRequest; + global $wgUser, $wgLang, $wgRequest, $wgLoadScript; // TODO: Should this be a static function of ResourceLoader instead? $query = array( 'modules' => implode( '|', array_unique( (array) $modules ) ), @@ -2292,9 +2292,9 @@ class OutputPage { ); // Automatically select style/script elements if ( $only === 'styles' ) { - return Html::linkedStyle( wfAppendQuery( wfScript( 'load' ), $query ) ); + return Html::linkedStyle( wfAppendQuery( $wgLoadScript, $query ) ); } else { - return Html::linkedScript( wfAppendQuery( wfScript( 'load' ), $query ) ); + return Html::linkedScript( wfAppendQuery( $wgLoadScript, $query ) ); } } diff --git a/includes/Setup.php b/includes/Setup.php index 6bf163efb5..002c128034 100644 --- a/includes/Setup.php +++ b/includes/Setup.php @@ -29,6 +29,7 @@ if ( !isset( $wgVersion ) ) { // Set various default paths sensibly... if( $wgScript === false ) $wgScript = "$wgScriptPath/index$wgScriptExtension"; if( $wgRedirectScript === false ) $wgRedirectScript = "$wgScriptPath/redirect$wgScriptExtension"; +if( $wgLoadScript === false ) $wgLoadScript = "$wgScriptPath/load$wgScriptExtension"; if( $wgArticlePath === false ) { if( $wgUsePathInfo ) {