Fandom Developers Wiki
m (If there are no translations there is no need to specify the parameter)
m (Rebranding: FANDOM → Fandom)
Line 19: Line 19:
 
The current workaround involves placing around 300 language codes in subpages of [[MediaWiki:Lang]]. That allows the MediaWiki message system to display the user language with <code><nowiki>{{int:lang}}</nowiki></code>.
 
The current workaround involves placing around 300 language codes in subpages of [[MediaWiki:Lang]]. That allows the MediaWiki message system to display the user language with <code><nowiki>{{int:lang}}</nowiki></code>.
   
For ease of deployment, we have a script to do the message setup. If you are setting this up on a FANDOM community, a Staff or IVT user must do it for you.}}}
+
For ease of deployment, we have a script to do the message setup. If you are setting this up on a Fandom community, a Staff or IVT user must do it for you.}}}
   
 
== {{{installation|Installation}}} ==
 
== {{{installation|Installation}}} ==

Revision as of 07:56, 9 January 2019

LangSetup automates deployment of MediaWiki:Lang subpages.

Rationale

There is no magic word or Lua variable for $wgUserLanguage in article wikitext. This is mainly due to caching - vanilla language detection would prevent caching and destroy performance.

The current workaround involves placing around 300 language codes in subpages of MediaWiki:Lang. That allows the MediaWiki message system to display the user language with {{int:lang}}.

For ease of deployment, we have a script to do the message setup. If you are setting this up on a Fandom community, a Staff or IVT user must do it for you.

Installation

Text above can be found here (edit)