Difference between revisions of "Template:T"
Jump to navigation
Jump to search
m |
|||
(12 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
− | + | <includeonly><code>{{[[Template:{{{1|}}}|{{{text|{{{1|}}}|}}}]]<!-- |
|
⚫ | |||
− | Templates tlc, tld, tlf have the following wrapping everything; do we need it? |
||
⚫ | |||
− | <span style="white-space:nowrap;"> |
||
⚫ | |||
− | --><!-- |
||
⚫ | |||
− | -- begin tt style if tt=yes given |
||
− | -->{{#if:{{{ |
+ | -->{{#if:{{{6|}}}||{{{6}}}|}}<!-- |
⚫ | |||
− | -- begin code style if code=yes given |
||
− | -->{{#if:{{{ |
+ | -->{{#if:{{{8|}}}||{{{8}}}|}}<!-- |
⚫ | |||
− | -- opening brace unless braceinside=yes |
||
⚫ | |||
− | -->{{#if:{{{braceinside|}}}||<nowiki>{{</nowiki>}}<!-- |
||
+ | == Documentation == |
||
− | -- add subst prefix, if subst=yes given |
||
+ | === Usage === |
||
− | -->{{#if:{{{subst|}}}|[[Help:Substitution|subst]]:}}<!-- |
||
+ | Usage is as follows: |
||
− | -- begin boldface if bold=yes given |
||
+ | |||
⚫ | |||
+ | {{t|t|template name|first parameter|second parameter}}. |
||
− | -- begin link if not nolink=yes; add any LANG and SISTER prefixes |
||
+ | |||
− | -->{{#if:{{{nolink|}}}||{{!(}}{{!(}}{{{LANG|}}}{{{SISTER|}}}<!-- |
||
+ | To pass named parameters, you can |
||
− | -- specify page to link to (unless nolink=yes) |
||
+ | * use <code>name &#<span>61</span>; value</code> — {{t|t|Rosharan numeric date|year &#<span>61</span>; 1172|month &#<span>61</span>; 5|week &#<span>61</span>; 10|day &#<span>61</span>; 6}}; |
||
− | -->{{#if:{{{1|}}}|{{#if:{{{anypage|}}}||{{ns:Template}}:}}{{{1|}}}|{{FULLPAGENAME}}}}{{!}}}}<!-- |
||
+ | * surround it in <code><nowiki><nowiki /></nowiki></code> tags — <code><nowiki>{{t|Rosharan numeric date|<nowiki>year=1172|month=5|week=1|day=6</nowiki></nowiki>}}</code>; or |
||
− | -- opening brace if braceinside=yes |
||
+ | * use correctly numbered parameters. |
||
− | -->{{#if:{{{braceinside|}}}|<nowiki>{{</nowiki>}}<!-- |
||
+ | |||
− | -- surface text of link |
||
+ | === More information === |
||
− | -->{{{alttext|{{{1|{{#ifeq:{{NAMESPACE}}|{{ns:Template}}|{{PAGENAME}}|{{FULLPAGENAME}}}}}}}}}}<!-- |
||
+ | {{for|Wikipedia: Template: Tlx|additional details and information}} |
||
− | -- closing brace if braceinside=yes |
||
+ | For additional details and information, please refer to the wikipedia's doc page: [[Wikipedia: Template: Tlx]] |
||
− | -->{{#if:{{{braceinside|}}}|<nowiki>}}</nowiki>}}<!-- |
||
+ | |||
− | -- end of link, unless nolink=yes |
||
+ | [[Category: Link macros]] |
||
⚫ | |||
− | -- end boldface if bold=yes |
||
⚫ | |||
− | -- add the remaining parameters |
||
− | -->{{#if:{{{2|}}}| |
||
− | |{{{2}}} |
||
− | }}<!-- |
||
− | -->{{#if:{{{3|}}}| |
||
− | |{{{3}}} |
||
− | }}<!-- |
||
− | -->{{#if:{{{4|}}}| |
||
− | |{{{4}}} |
||
− | }}<!-- |
||
− | -->{{#if:{{{5|}}}| |
||
− | |{{{5}}} |
||
− | }}<!-- |
||
− | -->{{#if:{{{6|}}}| |
||
− | |{{{6}}} |
||
− | }}<!-- |
||
− | -->{{#if:{{{7|}}}| |
||
− | |{{{7}}} |
||
− | }}<!-- |
||
− | -->{{#if:{{{8|}}}| |
||
− | |{{{8}}} |
||
− | }}<!-- |
||
⚫ | |||
− | |{{{9}}} |
||
− | }}<!-- |
||
− | -->{{#if:{{{10|}}}| |
||
− | |{{{10}}} |
||
− | }}<!-- |
||
− | -->{{#if:{{{11|}}}| |
||
− | |{{{11}}} |
||
− | }}<!-- |
||
− | -->{{#if:{{{12|}}}| |
||
− | |''...'' |
||
− | }}<!-- |
||
− | -- closing brace unless braceinside=yes |
||
− | -->{{#if:{{{braceinside|}}}||<nowiki>}}</nowiki>}}<!-- |
||
− | -- end code style if code=yes given |
||
⚫ | |||
− | -- end tt style if tt=yes given |
||
⚫ | |||
− | -- end |
||
⚫ | |||
− | This template allows you to link to a template. See [[Wikipedia:Template:Tlg]] for the original. |
Revision as of 16:36, 8 January 2018
Documentation
Usage
Usage is as follows:
{{t|template name|first parameter|second parameter}}
.
To pass named parameters, you can
- use
name = value
—{{t|Rosharan numeric date|year = 1172|month = 5|week = 10|day = 6}}
; - surround it in
<nowiki />
tags —{{t|Rosharan numeric date|<nowiki>year=1172|month=5|week=1|day=6</nowiki>}}
; or - use correctly numbered parameters.
More information
For additional details and information, please refer to the wikipedia's doc page: Wikipedia: Template: Tlx