Template:Protected/doc: Difference between revisions
More actions
+/- |
Undo revision 363394517 by Tim commons (talk): This template is for admins. Only admins should place (and remove) it, as it should be placed immediately after protection and removed immediately after unprotection, and only admins can protect/unprotect pages. |
||
| Line 1: | Line 1: | ||
{{TemplateBox | {{TemplateBox | ||
|1=1 | |1 = 1 | ||
|1d-en=—<!-- English description of the first parameter the template takes --> | |1d-en = —<!-- English description of the first parameter the template takes --> | ||
|1label=reason | |1label = reason | ||
|1aliases=<!-- List of aliases, separated by / (a slash) --> | |1aliases = <!-- List of aliases, separated by / (a slash) --> | ||
|1type=line | |1type = line | ||
|1def={{{{tSwitch|protected/text}}|default-reason}} | |1def = {{{{tSwitch|protected/text}}|default-reason}} | ||
|1stat=<!-- required, optional or optional-; optional- means it is optional and omitted in the usage-sample --> | |1stat = <!-- required, optional or optional-; optional- means it is optional and omitted in the usage-sample --> | ||
|2=icon | |||
|2label=hide icon | |2 = icon | ||
|2d-en=If this parameter has any value, the padlock icon doesn’t appear in the top-right corner. | |2label = hide icon | ||
|2d-td= | |2d-en = If this parameter has any value, the padlock icon doesn’t appear in the top-right corner. | ||
|2type=unknown | |2d-td = | ||
|2def= | |2type = unknown | ||
|2stat=optional- | |2def = | ||
|3=note | |2stat = optional- | ||
|3label=note | |||
|3d=It’s default value doesn’t show up on talk pages or user pages (if you specify the parameter, it does so). | |3 = note | ||
|3d-td= | |3label = note | ||
|3type=line | |3d = It’s default value doesn’t show up on talk pages or user pages (if you specify the parameter, it does so). | ||
|3def={{{{tSwitch|protected/text}}|text2}} (except talk and user pages) | |3d-td = | ||
|3stat=optional- | |3type = line | ||
|name=protected | |3def = {{{{tSwitch|protected/text}}|text2}} (except talk and user pages) | ||
|desc=General protection template to inform users a page is protected. (Note: This does not protect pages. Only admins can do that.) | |3stat = optional- | ||
|namespace=all | |||
|usergroup= | |name = protected | ||
|placement= | |desc = General protection template to inform users a page is protected. (Note: This does not protect pages. Only admins can do that.) | ||
|usage-notes= | |namespace = all | ||
|type= | |usergroup = admin | ||
|example= | |placement = | ||
|example-value= | |usage-notes = | ||
|i18n-method=ext.translate | |type = | ||
|i18n-desc=Only the text is switched out based on the user's interface, not the whole template (like with {{tl|autotranslate}}) to avoid unnecessary complexity. Keep in mind this is still a work in progress and new text fields may be added in the future. | |example = | ||
|i18n-mediawiki-msg= | |example-value = | ||
|i18n-subpage=text | |i18n-method = ext.translate | ||
|seealso= | |i18n-desc = Only the text is switched out based on the user's interface, not the whole template (like with {{tl|autotranslate}}) to avoid unnecessary complexity. Keep in mind this is still a work in progress and new text fields may be added in the future. | ||
|i18n-mediawiki-msg = | |||
|i18n-subpage = text | |||
|seealso = | |||
*{{tl|Mprotected}} - for images included on the [[Main Page]], which are protected because of the cascading protection (but are not protected directly). | *{{tl|Mprotected}} - for images included on the [[Main Page]], which are protected because of the cascading protection (but are not protected directly). | ||
*{{tl|permprot}} - for high-risk templates that are indefinitely protected (use on talk page). | *{{tl|permprot}} - for high-risk templates that are indefinitely protected (use on talk page). | ||
*{{tl|MWheader}} - for MediaWiki pages (use on talk page). | *{{tl|MWheader}} - for MediaWiki pages (use on talk page). | ||
=== Padlocks === | === Padlocks === | ||
* [[File:Full-protection-shackle-block.svg|20px]] = full protection from editing. | * [[File:Full-protection-shackle-block.svg|20px]] = full protection from editing. | ||
| Line 43: | Line 47: | ||
* [[File:Semi-protection-shackle.svg|20px]] = semi protection from editing or uploading. | * [[File:Semi-protection-shackle.svg|20px]] = semi protection from editing or uploading. | ||
* [[File:Upload-protection-shackle.svg|20px]] = full protection from uploading (but not editing). | * [[File:Upload-protection-shackle.svg|20px]] = full protection from uploading (but not editing). | ||
|setscats=files to [[:Category:Protected files]] and everything else except user pages, user talk pages, and templates to [[:Category:Protected pages]]. If the page is not protected, it will end up in [[:Category:Unprotected pages using protection templates]]. | |setscats = files to [[:Category:Protected files]] and everything else except user pages, user talk pages, and templates to [[:Category:Protected pages]]. If the page is not protected, it will end up in [[:Category:Unprotected pages using protection templates]]. | ||
|print= | |print = | ||
|shorthand= | |shorthand = | ||
|relieson= | |relieson = | ||
|mustbesubst= | |mustbesubst = | ||
}} | }} | ||
== Examples == | == Examples == | ||
:''The message box does not appear on semi-protected pages or upload-only protected files. An icon still appears in the top-right corner.'' | :''The message box does not appear on semi-protected pages or upload-only protected files. An icon still appears in the top-right corner.'' | ||
Revision as of 20:53, 27 August 2019
General protection template to inform users a page is protected. (Note: This does not protect pages. Only admins can do that.)
The template automatically sets the following categories: files to Category:Protected files and everything else except user pages, user talk pages, and templates to Category:Protected pages. If the page is not protected, it will end up in Category:Unprotected pages using protection templates.
Usage
{{protected |1= }}
Template parameters
| Parameter | Description | Default | Status | |
|---|---|---|---|---|
1 | reason | — | from editing to prevent vandalism. | optional |
icon | hide icon | If this parameter has any value, the padlock icon doesn’t appear in the top-right corner. | empty | optional |
note | note | It’s default value doesn’t show up on talk pages or user pages (if you specify the parameter, it does so). | Please discuss changes on the talk page or request unprotection. (except talk and user pages) | optional |
Additional information
The template is intended to be used in the following namespaces: all namespaces
The template is intended to be used by the following user groups: Administrators
See also
- {{Mprotected}} - for images included on the Main Page, which are protected because of the cascading protection (but are not protected directly).
- {{Permprot}} - for high-risk templates that are indefinitely protected (use on talk page).
- {{MWheader}} - for MediaWiki pages (use on talk page).
Padlocks
Localization
العربية ∙ беларуская (тарашкевіца) ∙ বাংলা ∙ dansk ∙ Deutsch ∙ English ∙ español ∙ فارسی ∙ français ∙ galego ∙ עברית ∙ हिन्दी ∙ hrvatski ∙ magyar ∙ italiano ∙ 日本語 ∙ 한국어 ∙ македонски ∙ മലയാളം ∙ मराठी ∙ မြန်မာဘာသာ ∙ Nederlands ∙ polski ∙ português ∙ português do Brasil ∙ русский ∙ slovenščina ∙ српски / srpski ∙ svenska ∙ ไทย ∙ Türkçe ∙ українська ∙ 中文
This template makes use of {{Autotranslate}} and the translate extension.
Only the text is switched out based on the user's interface, not the whole template (like with {{Autotranslate}}) to avoid unnecessary complexity. Keep in mind this is still a work in progress and new text fields may be added in the future.
Examples
- The message box does not appear on semi-protected pages or upload-only protected files. An icon still appears in the top-right corner.
{{protected}} →
| This template has been protected from editing to prevent vandalism. Please discuss changes on the talk page or request unprotection. |
{{protected|I said so}} →
| This template has been protected because I said so. Please discuss changes on the talk page or request unprotection. |
{{protected|note=And you can change this too.}} →
| This template has been protected from editing to prevent vandalism. And you can change this too. |