Template:Protection: Difference between revisions
No edit summary |
(new layout) |
||
Line 1: | Line 1: | ||
<noinclude>{{ | <noinclude> | ||
| | {{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. | ||
| | |||
| | The "reason" parameter is optional and should be used to provide a reason for the protection. | ||
==Usage== | |||
}} | <pre>{{Protection}}</pre> | ||
:'''Produces:''' | |||
{{Protection}} | |||
:'''OR''' | |||
<pre>{{Protection|This template is consider '''High Risk''' as it is used on multiple pages.}}</pre> | |||
:'''Produces:''' | |||
{{Protection|This template is considered '''High Risk''' as it is used on multiple pages.}} | |||
{{Translation guide|<syntaxhighlight lang="html"> | |||
{{#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 = [[Category:Incorrect template usage]] | |||
}} | |||
</syntaxhighlight>}} | |||
}} | |||
{{ll|Category:Maintenance templates}} | |||
{{ll|Category:Mbox templates}} | |||
</noinclude><includeonly>{{Mbox | |||
| color = #bbbbaa | |||
| sign = [[File:Lock-locked.png|link=Template:Protection{{#ifeq:{{Language code}}|true|{{Subpage}}|}}]] | |||
| title = {{tt | |||
| name = Protection | |||
| default = This page has been put into protection by a PZwiki [[PZwiki:Administrators|administrator]]. | |||
| arg1 = title | |||
}} | |||
| content = {{tt | |||
| name = Protection | |||
| default = Reason | |||
| arg1 = reason | |||
}}: {{#if:{{{1|}}}|{{{1}}}|...}} | |||
| note = {{#if: {{PROTECTIONLEVEL:edit|}} | |||
| {{tt | |||
| name = Protection | |||
| default = Only users in the [[PZwiki:{{PROTECTIONLEVEL:edit}}|{{PROTECTIONLEVEL:edit}}]] [[Special:ListGroupRights|user group]] may edit this page. | |||
| arg1 = note | |||
}} | |||
}} | |||
| id = mbox-protect | |||
| collapsed = {{#if:{{{1|}}}||{{{1}}}}} | |||
}}</includeonly> |
Revision as of 14:06, 28 December 2023
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 "reason" parameter is optional and should be used to provide a reason for the protection.
Usage
{{Protection}}
- Produces:
- OR
{{Protection|This template is consider '''High Risk''' as it is used on multiple pages.}}
- Produces:
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 = [[Category:Incorrect template usage]]
}}
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.