Template:String: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(Created page with "{{Warning|Designed for the new page format. Please do not use or edit this template yet.}} Alternative version of {{Tl|autolang}} template. {{Important|If your default text...")
 
mNo edit summary
Line 28: Line 28:




<includeonly><onlyinclude>{{{{{{force}}}|{{{{{{-{{intlang}}}}}|{{{{{intlang}}|{{{1|}}}}}}}}}}}}</onlyinclude></includeonly>
<includeonly><onlyinclude>{{{{{{-{{{force|{{intlang}}}}}}}}|{{{{{{force|{{intlang}}}}}|{{{1|}}}}}}}}}</onlyinclude></includeonly>

Revision as of 05:55, 15 April 2024

Warning.pngWarning:Designed for the new page format. Please do not use or edit this template yet.


Alternative version of {{autolang}} template.

Icon-Important.pngImportant:If your default text is not displayed, try adding 1= at the beginning of parameter.


Common use of the template:

{{String|Default Text|ru=Russian Text|it=Italian Text}} → Default Text


Default text is empty (in a language that is not specified there will be an empty line):

{{String|en=English Text|it=Italian Text}} → English Text


The {{{force}}} parameter forces the template to intentionally load the selected language (useful for testing):

{{String|Default Text|force=ru|es=Spanish Text|ru=Russian Text|it=Italian Text}} → Russian Text

Note.pngNote:To force Default text to be displayed, use force=1


By using a hyphen before the language code, it can be linked to any other language (even to default text):

{{String|Default Text|-en=it|it=Some Text}} → Some Text

Note.pngNote:To link a language (for example Spanish) to the default text, use -es=1