Template:Uw/doc: Difference between revisions
More actions
No edit summary |
Undo revision 677522048 by Seikan Tunnel (talk) |
||
| Line 50: | Line 50: | ||
|i18n-method=- | |i18n-method=- | ||
|type= | |type= | ||
|example= | |example=Username | ||
|seealso= | |seealso= | ||
|setscats= | |setscats= | ||
| Line 60: | Line 60: | ||
==== More examples ==== | ==== More examples ==== | ||
{{Tle|t=Uw| | {{Tle|t=Uw|Username|-}} gives {{Uw|Username|-}} <br> | ||
{{Tle|t=Uw| | {{Tle|t=Uw|Username|+}} gives {{Uw|Username|+}} <br> | ||
{{Tle|t=Uw| | {{Tle|t=Uw|Username|commons|-}} gives {{Uw|Username|commons|-}} <br> | ||
{{Tle|t=Uw| | {{Tle|t=Uw|Username|Comm~user|-|p4=link|no}} gives {{Uw|Username|Comm~user|-|link=no}} <br> | ||
{{Tle|t=Uw| | {{Tle|t=Uw|Username|Comm~user|-|p4=link|no|p5=case|l}} gives {{Uw|Username|Comm~user|-|link=no|case=l}}<br> | ||
{{Tle|t=Uw| | {{Tle|t=Uw|User|Spain~user|es|-|p5=case|i|p6=i18n|es}} gives {{Uw|User|Spain~user|es|-|case=i|i18n=es}} | ||
==== Language code exampless ==== | ==== Language code exampless ==== | ||
<nowiki>{{Uw| | <nowiki>{{Uw|Willy on Wheels}}</nowiki> gives {{Uw|Willy on Wheels}}<br> | ||
<nowiki>{{Uw| | <nowiki>{{Uw|Willy on Wheels||}}</nowiki> gives {{Uw|Willy on Wheels||}}<br> | ||
<nowiki>{{Uw| | <nowiki>{{Uw|Willy on Wheels|WoW}}</nowiki> gives {{Uw|Willy on Wheels|WoW}}<br> | ||
<nowiki>{{Uw| | <nowiki>{{Uw|Willy on Wheels|WoW|}}</nowiki> gives {{Uw|Willy on Wheels|WoW|}}<br> | ||
<nowiki>{{Uw| | <nowiki>{{Uw|Willy on Wheels|WoW|et}}</nowiki> gives {{Uw|Willy on Wheels|WoW|et}}<br> | ||
<nowiki>{{Uw| | <nowiki>{{Uw|Willy on Wheels||et}}</nowiki> gives {{Uw|Willy on Wheels||et}}<br> | ||
<small>{{Lua|Module:LangSwitch}}</small> | <small>{{Lua|Module:LangSwitch}}</small> | ||
{{namespace/display|t=<includeonly>{{PAGENAME}}</includeonly><noinclude>Uw</noinclude> | {{namespace/display|t=<includeonly>{{PAGENAME}}</includeonly><noinclude>Uw</noinclude> | ||
|name= | |name=username|par2=~commonswiki}} | ||
{{clr}} | {{clr}} | ||
<span style="float:right" class="editsection"><nowiki>[</nowiki>{{Edit-int|Commons:Link templates/User and user talk links}} <!-- user links --><nowiki>]</nowiki></span> | <span style="float:right" class="editsection"><nowiki>[</nowiki>{{Edit-int|Commons:Link templates/User and user talk links}} <!-- user links --><nowiki>]</nowiki></span> | ||
Revision as of 07:01, 25 July 2022
User page link, only within Commons, when user names are trailed with "~commonswiki"
Usage
{{U |1= }}
Template parameters
| Parameter | Description | Default | Status | |
|---|---|---|---|---|
1 | user name, without the trailing "~commonswiki" | empty | required | |
2 | display name (nick name): may be formatted | param #1 | optional | |
3 | ISO 639 language code; If absent: ~ommonswiki | empty | optional | |
4 | + or - to precede the user name with the namespace User:
(if both signs are specified, "+" is used and "-" is ignored) | empty | optional | |
link | specify link=no to suppress the link | empty | optional | |
| more parameters to format the namespace (when "+" or "-" is specified)
| optional | ||
case | for formatting of the namespace:
| empty | optional | |
i18n | an ISO 639 language code, to follow another translation then yours
| en | optional | |
Additional information
The template is intended to be used in the following namespaces: no namespace specified
The template is intended to be used by the following user groups: no user group specified
Example
{{U|Username}}
renders as:
Localization
This template is not intended to be localized.
More examples
{{ Uw | Username | - }} gives User:Username
{{ Uw | Username | + }} gives User:Username
{{ Uw | Username | commons | - }} gives User:commons
{{ Uw | Username | Comm~user | - | link = no }} gives User:Comm~user
{{ Uw | Username | Comm~user | - | link = no | case = l }} gives user:Comm~user
{{ Uw | User | Spain~user | es | - | case = i | i18n = es }} gives LangSwitch Error: no default:Spain~user
Language code exampless
{{Uw|Willy on Wheels}} gives Willy on Wheels
{{Uw|Willy on Wheels||}} gives Willy on Wheels
{{Uw|Willy on Wheels|WoW}} gives WoW
{{Uw|Willy on Wheels|WoW|}} gives WoW
{{Uw|Willy on Wheels|WoW|et}} gives WoW
{{Uw|Willy on Wheels||et}} gives Willy on Wheels
| Table: different displays for {{Uw}} with the namespace option | |
|---|---|
| {{ Uw | username }} this is the standard | username |
| {{ Uw | username | - }} | User:username |
| {{ Uw | username | - | case = l }} | user:username |
| {{ Uw | username | - | case = i }} | LangSwitch Error: no default:username |
| {{ Uw | username | - | case = n }} | user:username |
| {{ Uw | username | + }} | User:username |
| {{ Uw | username | + | case = l }} | user:username |
| {{ Uw | username | + | case = i }} | user:username |
| {{ Uw | username | + | case = n }} | user:username |
| {{ Uw | username | link = n }} | username |
| {{ Uw | username | - | link = n }} | User:username |
| {{ Uw | username | - | link = n | case = l }} | user:username |
| {{ Uw | username | - | link = n | case = i }} | LangSwitch Error: no default:username |
| {{ Uw | username | - | link = n | case = n }} | user:username |
| {{ Uw | username | + | link = n }} | User:username |
| {{ Uw | username | + | link = n | case = l }} | user:username |
| {{ Uw | username | + | link = n | case = i }} | LangSwitch Error: no default:username |
| {{ Uw | username | + | link = n | case = n }} | user:username |
[ ] {{Commons:Link templates/User and user talk links}}