Difference between revisions of "Template:Translations"

From Creative Commons
Jump to: navigation, search
(corrected detection of the existence of a language code, for pages without a language code)
(restore forcing of a lowercase language code)
Line 6: Line 6:
 
<td style="background: #F6F9ED;padding-left:10px;">{{#if:{{{articles|}}}|{{#arraymap:{{{articles}}}|,|x|[[Has translation::x]]|,  }}|[[Category:Untranslated]] There are no known translations for this page. Please read the directions on [[CcWiki:Translate|how to add a translation]].}}{{#ifeq:{{#explode:{{SUBPAGENAME}}|:|0}}|{{SUBPAGENAME}}
 
<td style="background: #F6F9ED;padding-left:10px;">{{#if:{{{articles|}}}|{{#arraymap:{{{articles}}}|,|x|[[Has translation::x]]|,  }}|[[Category:Untranslated]] There are no known translations for this page. Please read the directions on [[CcWiki:Translate|how to add a translation]].}}{{#ifeq:{{#explode:{{SUBPAGENAME}}|:|0}}|{{SUBPAGENAME}}
 
|[[Has language::{{CONTENTLANGUAGE}}| ]]
 
|[[Has language::{{CONTENTLANGUAGE}}| ]]
|[[Has language::{{#explode:{{SUBPAGENAME}}|:|0}}| ]]}}</td>
+
|[[Has language::{{lc:{{#explode:{{SUBPAGENAME}}|:|0}}}}| ]]}}</td>
 
</tr></table></div>
 
</tr></table></div>
 
</includeonly><noinclude>
 
</includeonly><noinclude>

Revision as of 01:37, 18 April 2011


This is the Translations template. It can be used to link to translations of an article in the wiki. To use it in your article, insert it as follows:

{{Translations|
   articles=Es:Foo,Hr:Bar
}}

Any number of translations can be listed in the articles parameter, separated by commas.

If no translations are specified, the page is marked as Untranslated.

See also