Template:GlobalText
From NovaRoma
(Difference between revisions)
m (cut out extra white space) |
(enable RO) |
||
Line 1: | Line 1: | ||
<includeonly>{{#switch: {{NAMESPACE}} | <includeonly>{{#switch: {{NAMESPACE}} | ||
− | |||
− | |||
| DE = {{#if: {{{DE|}}} | {{{DE}}}| {{{EN|}}}}} | | DE = {{#if: {{{DE|}}} | {{{DE}}}| {{{EN|}}}}} | ||
− | |||
| ES = {{#if: {{{ES|}}} | {{{ES}}}| {{{EN|}}}}} | | ES = {{#if: {{{ES|}}} | {{{ES}}}| {{{EN|}}}}} | ||
− | | | + | | FR = {{#if: {{{FR|}}} | {{{FR}}}| {{{EN|}}}}} |
| HU = {{#if: {{{HU|}}} | {{{HU}}}| {{{EN|}}}}} | | HU = {{#if: {{{HU|}}} | {{{HU}}}| {{{EN|}}}}} | ||
+ | | IT = {{#if: {{{IT|}}} | {{{IT}}}| {{{EN|}}}}} | ||
+ | | LA = {{#if: {{{LA|}}} | {{{LA}}}| {{{EN|}}}}} | ||
+ | | PT = {{#if: {{{PT|}}} | {{{PT}}}| {{{EN|}}}}} | ||
+ | | RO = {{#if: {{{RO|}}} | {{{RO}}}| {{{EN|}}}}} | ||
| {{{EN|}}} }}</includeonly> <noinclude>[[Category:Templates]] | | {{{EN|}}} }}</includeonly> <noinclude>[[Category:Templates]] | ||
==Purpose== | ==Purpose== | ||
− | This function will provide language-context sensitive text. In the | + | This function will provide language-context sensitive text. In the DE, ES, FR, HU, IT, LA, PT, RO namespaces, text will appear in the namespace language, if provided. In all other namespaces, and in the case that no translation is provided, the English text will appear.. |
==Scope== | ==Scope== | ||
Line 18: | Line 19: | ||
==Usage== | ==Usage== | ||
− | <nowiki>{{GlobalText|EN = English text| | + | <nowiki>{{GlobalText|DE = German text|EN = English text|ES = Spanish text|FR = French text|HU = Hungarian text|IT = Italian text|LA = Latin text|PT = Portuguese text|RO = Romanian text}}</nowiki> |
All values are optional, except that the English text is used as a default, so should always be provided. If no texts are provided, nothing will be returned. | All values are optional, except that the English text is used as a default, so should always be provided. If no texts are provided, nothing will be returned. | ||
</noinclude> | </noinclude> |
Revision as of 08:34, 22 February 2008
Purpose
This function will provide language-context sensitive text. In the DE, ES, FR, HU, IT, LA, PT, RO namespaces, text will appear in the namespace language, if provided. In all other namespaces, and in the case that no translation is provided, the English text will appear..
Scope
This template will generally be used to globalize other templates. There is no point to using it in articles directly.
Usage
{{GlobalText|DE = German text|EN = English text|ES = Spanish text|FR = French text|HU = Hungarian text|IT = Italian text|LA = Latin text|PT = Portuguese text|RO = Romanian text}}
All values are optional, except that the English text is used as a default, so should always be provided. If no texts are provided, nothing will be returned.