Template: Languages
From LibrePlanet
m (minor info added) |
|||
Line 2: | Line 2: | ||
This is the "Languages" template. | This is the "Languages" template. | ||
− | It shows the available translations of a page. Only works if translations URL are in the "correct" way (i.e.: PageName/ | + | It shows the available translations of a page. Only works if translations URL are in the "correct" way (i.e.: PageName/fr) |
It should be called in the following format: | It should be called in the following format: | ||
Line 11: | Line 11: | ||
Edit the page to see the template text. | Edit the page to see the template text. | ||
</noinclude> | </noinclude> | ||
− | {{ | + | <includeonly> |
− | + | {{#ifeq:{{#ask: [[master page::{{{master page}}}]] [[language code::!{{{language}}}]]|format=count}}|0||<div style="text-align: left; background: #F7F7F7; border: 1px solid #B0BFE8; padding: 0.5em; "> | |
− | + | {{Languages/Title|{{SUBPAGENAME}}}}]] | |
− | + | {{#ask: [[master page::{{{master page}}}]] [[language code::!{{{language}}}]]| | |
− | + | ?language code =| | |
− | + | link=none| | |
− | + | format=list| | |
− | + | sep=,_| | |
− | + | template=languagelink| | |
− | + | sort = language code| | |
− | + | order = asc| | |
− | + | limit = 10| | |
− | + | searchlabel = […] | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | } | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
}} | }} | ||
+ | </div>}} | ||
+ | <div style="display: none; read: none;"> | ||
+ | [[master page::{{{master page}}}]] [[language code::{{{language}}}]] | ||
+ | </div> | ||
+ | </includeonly> |
Revision as of 13:44, 23 January 2011
This is the "Languages" template.
It shows the available translations of a page. Only works if translations URL are in the "correct" way (i.e.: PageName/fr)
It should be called in the following format:
{{Languages|PageName}}
Edit the page to see the template text.