if ( $this->getSession( 'test' ) === null && !$this->request->wasPosted() ) {
$wgLanguageCode = $this->getAcceptLanguage();
$wgLang = $wgContLang = Language::factory( $wgLanguageCode );
+ RequestContext::getMain()->setLanguage( $wgLang );
$this->setVar( 'wgLanguageCode', $wgLanguageCode );
$this->setVar( '_UserLang', $wgLanguageCode );
} else {
if ( !$status->isGood() ) {
$text = $status->getWikiText();
- if ( $status->isOk() ) {
+ if ( $status->isOK() ) {
$box = $this->getWarningBox( $text );
} else {
$box = $this->getErrorBox( $text );
*/
public function downloadLinkHook( $text, $attribs, $parser ) {
$anchor = Html::rawElement( 'a',
- [ 'href' => $this->getURL( [ 'localsettings' => 1 ] ) ],
+ [ 'href' => $this->getUrl( [ 'localsettings' => 1 ] ) ],
wfMessage( 'config-download-localsettings' )->parse()
);
return Html::rawElement( 'div', [ 'class' => 'config-download-link' ], $anchor );
}
+ /**
+ * If the software package wants the LocalSettings.php file
+ * to be placed in a specific location, override this function
+ * (see mw-config/overrides/README) to return the path of
+ * where the file should be saved, or false for a generic
+ * "in the base of your install"
+ *
+ * @since 1.27
+ * @return string|bool
+ */
+ public function getLocalSettingsLocation() {
+ return false;
+ }
+
/**
* @return bool
*/