Template:Protection: Difference between revisions
m (update) |
m (Automated template error handling update) |
||
(5 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
<noinclude> | <noinclude> | ||
{{Documentation/sandbox|doc = | {{Documentation/sandbox|doc= | ||
Added to pages that have some level of protection. The level of protection is automatically displayed, if there is no protection, nothing will display, apart from the base message. | Added to pages that have some level of protection. The level of protection is automatically displayed, if there is no protection, nothing will display, apart from the base message. | ||
Line 13: | Line 13: | ||
*{{tll|Protection}} | *{{tll|Protection}} | ||
{{Protection}} | {{Protection}} | ||
*{{tll|Protection|This template is | *{{tll|Protection|This template is considered '''High Risk''' as it is used on multiple pages.}} | ||
{{Protection|This template is considered '''High Risk''' as it is used on multiple pages.}} | {{Protection|This template is considered '''High Risk''' as it is used on multiple pages.}} | ||
Line 21: | Line 21: | ||
| reason = Reason | | reason = Reason | ||
| note = Only users in the [[PZwiki:{{PROTECTIONLEVEL:edit}}|{{PROTECTIONLEVEL:edit}}]] [[Special:ListGroupRights|user group]] may edit this page. | | note = Only users in the [[PZwiki:{{PROTECTIONLEVEL:edit}}|{{PROTECTIONLEVEL:edit}}]] [[Special:ListGroupRights|user group]] may edit this page. | ||
| #default = | | #default = {{Error|translation}} | ||
}} | }} | ||
</syntaxhighlight>}} | </syntaxhighlight>}} | ||
Line 28: | Line 28: | ||
*{{ll|PZwiki:Mboxes}} | *{{ll|PZwiki:Mboxes}} | ||
}} | }} | ||
{{ll|Category:Mbox | {{ll|Category:Mbox}} | ||
</noinclude><includeonly>{{Mbox | </noinclude><includeonly>{{Mbox | ||
| color = #bbbbaa | | color = #bbbbaa | ||
| sign = [[File:Lock-locked.png|link=Template:Protection{{lcs}}]] | | sign = [[File:Lock-locked.png|link=Template:Protection{{lcs}}]] | ||
| title = {{tt|name = Protection | | title = {{tt|name=Protection | ||
| default = This page has been put into protection by a PZwiki [[PZwiki:Administrators|administrator]]. | | default = This page has been put into protection by a PZwiki [[PZwiki:Administrators|administrator]]. | ||
| arg1 = title | | arg1 = title | ||
}} | }} | ||
| content = {{tt|name = Protection | | content = {{#if:{{{1|}}}|{{tt|name=Protection | ||
| default = Reason | | default = Reason | ||
| arg1 = reason | | arg1 = reason | ||
}}: | }}: {{{1}}}}} | ||
| note = {{#if: {{PROTECTIONLEVEL:edit|}} | | note = {{#if: {{PROTECTIONLEVEL:edit|}} | ||
| {{tt|name = Protection | | {{tt|name = Protection | ||
Line 46: | Line 46: | ||
}} | }} | ||
}} | }} | ||
| id = | | id = protect | ||
| collapsed = {{#if:{{{1|}}}||true}} | | collapsed = {{#if:{{{1|}}}||true}} | ||
}}</includeonly> | }}</includeonly> |
Revision as of 08:46, 11 March 2024
Added to pages that have some level of protection. The level of protection is automatically displayed, if there is no protection, nothing will display, apart from the base message.
The first parameter is optional and should be used to provide a reason for the protection.
Usage
Parameters
1
- The reason for the protection.
Examples
{{Protection}}
{{Protection|This template is considered High Risk as it is used on multiple pages.}}
How to translate
This template is translatable.
Template code
Paste the following code into the <includeonly>
tag of the translated template and translate the text after each =
sign (except for #default =
).
{{#switch:{{{1|}}}
| title = This page has been put into protection by a PZwiki [[PZwiki:Administrators|administrator]].
| reason = Reason
| note = Only users in the [[PZwiki:{{PROTECTIONLEVEL:edit}}|{{PROTECTIONLEVEL:edit}}]] [[Special:ListGroupRights|user group]] may edit this page.
| #default = {{Error|translation}}
}}
Template documentation
Copy the code wrapped in the <noinclude>
tag in this template and translate the text after doc =
in the {{Documentation}}
template.
{{Translation guide}}
template should be removed from the translated documentation.