Template:Plugin/doc: Difference between revisions

From Miranda NG
Jump to navigation Jump to search
(categories should be in docs)
No edit summary
 
(3 intermediate revisions by one other user not shown)
Line 1: Line 1:
{{Documentation subpage}}
{{Documentation subpage}}{{PageLang|en}}


 
Creates link to plugin's page. Link will lead to page in user's interface language; if it doesn't exist, then to page in fallback language or to English one in the end. So it should always lead to valid, existing page (in case page in base language exists – like it should).
__TOC__


== Usage ==
== Usage ==
=== In the Namespace:Plugin and on pages with language code in the name ===
If you need to link from plugin page to another plugin page or from pages with language code in the name like Langpacks/en‎.


==== Single link ====
==== Single link ====
Line 16: Line 13:
! You type !! You get
! You type !! You get
|-
|-
| <nowiki>{{Plugin|AIM}}</nowiki> || {{Plugin|en|AIM}}
| <nowiki>{{Plugin|AIM}}</nowiki> || {{Plugin|AIM}}
|-
|-
| <nowiki>{{Plugin|AIM|AIM Protocol}}</nowiki> || {{Plugin|en|AIM|AIM Protocol}}
| <nowiki>{{Plugin|AIM|AIM Protocol}}</nowiki> || {{Plugin|AIM|AIM Protocol}}
|}
|}


Line 29: Line 26:
! You type !! You get
! You type !! You get
|-
|-
| <nowiki>{{While|tpl=Plugin|AIM|Facebook|Jabber}}</nowiki> || {{While|tpl=Plugin|p1=en|AIM|Facebook|Jabber}}
| <nowiki>{{While|tpl=Plugin|AIM|Facebook|Jabber}}</nowiki> || {{While|tpl=Plugin|AIM|Facebook|Jabber}}
|}
 
=== Other pages ===
If you need to link from other pages, you have to specify the language.
 
==== Single link ====
<pre style="overflow:auto;">
{{Plugin | Language code | Plugin name | Link name (optional) }}
</pre>
 
{| class="wikitable" align="center"
! You type !! You get
|-
| <nowiki>{{Plugin|en|AIM}}</nowiki> || {{Plugin|en|AIM}}
|-
| <nowiki>{{Plugin|en|AIM|AIM Protocol}}</nowiki> || {{Plugin|en|AIM|AIM Protocol}}
|}
 
==== Using Template:While ====
<pre style="overflow:auto;">
{{While | tpl=Plugin | p1=Language code | Name of the first plugin | Name of the second plugin | etc. }}
</pre>
 
{| class="wikitable" align="center"
! You type !! You get
|-
| <nowiki>{{While|tpl=Plugin|p1=en|AIM|Facebook|Jabber}}</nowiki> || {{While|tpl=Plugin|p1=en|AIM|Facebook|Jabber}}
|}
|}
<includeonly>
<includeonly>

Latest revision as of 16:29, 3 February 2018

This is a documentation subpage for Template:Plugin .
It contains usage information, categories and other content that is not part of the original template page.

Creates link to plugin's page. Link will lead to page in user's interface language; if it doesn't exist, then to page in fallback language or to English one in the end. So it should always lead to valid, existing page (in case page in base language exists – like it should).

Usage

Single link

{{Plugin | Plugin name | Link name (optional) }}
You type You get
{{Plugin|AIM}} AIM
{{Plugin|AIM|AIM Protocol}} AIM Protocol

Using Template:While

{{While | tpl=Plugin | Name of the first plugin | Name of the second plugin | etc. }}
You type You get
{{While|tpl=Plugin|AIM|Facebook|Jabber}} AIM, Facebook, Jabber