Difference between revisions of "Template:Check file on delete/sandbox"

From blackwiki
Jump to navigation Jump to search
imported>Davidgothberg
(Adding the top 100 images.)
imported>Adem20
m (+template)
 
(9 intermediate revisions by one other user not shown)
Line 2: Line 2:
 
   {{#switch: {{PAGENAME}}
 
   {{#switch: {{PAGENAME}}
 
   <!-- Images used in system messages: -->
 
   <!-- Images used in system messages: -->
 +
  | Lock icon blue.gif
 +
  | Example.jpg
 +
 +
  | Button redirect.png
 +
  | Button strike.png
 +
  | Button enter.png
 +
  | Button upper letter.png
 +
  | Button lower letter.png
 +
  | Button small.png
 +
  | Button hide comment.png
 +
  | Button gallery.png
 +
  | Button blockquote.png
 +
  | Button insert table.png
 +
  | Button reflink.png
 +
 +
  | Monobook-bullet.png
 +
  | Monobook-bullet-ga.png
 +
  | Monobook-bullet-star.png
 +
 +
  | Button link.png
 +
  | Crystal 128 kivio.png
 +
  | Gtk-dialog-info-14px.png
 +
  | Imbox content.png
 +
  | Imbox notice.png
 +
  | Imbox style.png
 +
  | Nuvola actions undo.png
 +
 +
  | Ambox warning orange.svg
 +
  | Ambox warning pn.svg
 +
  | Ambox warning yellow.svg
 +
  | Circle-style-warning.svg
 +
  | Commons-logo.svg
 +
  | Crystal Clear app amor.png
 +
  | Crystal Clear app help index.png
 +
  | Crystal Clear app ktip.png
 +
  | Crystal Clear app lphoto.png
 +
  | Emblem-question-yellow.svg
 +
  | Mail-send-receive.svg
 +
  | Namespace MediaWiki.svg
 +
  | Padlock.svg
 +
  | Padlock-red.svg
 +
  | Pango-name.svg
 +
  | Template-info.svg
 
   | User-info.svg
 
   | User-info.svg
   | Example.jpg = system
+
   | Yes check.svg
 +
  | Wiki letter w.svg
 +
 
 +
  <!-- Other known high-risk images: -->
 +
  | Ambox deletion.png
 +
  | Padlock-silver-medium.svg
 +
  | Padlock-olive.svg
 +
  | Padlock-black.svg
 +
  | Padlock-skyblue.svg
 +
  | Cscr-featured.svg
 +
 
 +
  <!-- Images from the image upload interface: -->
 +
  | Icon - upload photo.svg
 +
  | Commons-logo-en.svg
 +
  | Questionmark copyright.svg
 +
  | Gtk-go-back-ltr.svg
 +
  | Emblem-important.svg
 +
  | Searchtool.svg
 +
  | Cc-nc white.svg
 +
  | Cc-nd white.svg
 +
  | Green check.png
  
 
   <!-- The 50 most used images on Wikipedia: -->
 
   <!-- The 50 most used images on Wikipedia: -->
Line 109: Line 172:
 
   | Baseball (crop).jpg = high-risk
 
   | Baseball (crop).jpg = high-risk
  
   }} {{{test1|}}} <noinclude>aaa</noinclude>
+
   }} {{{demo1|}}} <noinclude>aaa</noinclude>
  
 
| {{fmbox
 
| {{fmbox
Line 116: Line 179:
 
   | id = mw-filedelete-intro-high-risk
 
   | id = mw-filedelete-intro-high-risk
 
   | text =  
 
   | text =  
'''Warning!''' This file is used in a system message or is one of the most widely used images. Such high-risk images should be locally uploaded and protected here at the English Wikipedia. Don't delete this image, not even if it has a backup copy on Commons.
+
'''Warning!''' This file is used in a system message or is one of the most widely used images. Such high-risk images should be locally uploaded and protected here at the English Wikipedia. Don't delete this image, not even if it has a backup copy on Commons. <small>([[Wikipedia talk:Cascade-protected items#About high-risk images|more about this]])</small> {{
 +
    #if: {{PROTECTIONLEVEL:edit}} {{PROTECTIONLEVEL:move}} {{PROTECTIONLEVEL:create}} {{PROTECTIONLEVEL:upload}}
 +
    | <br />This file has the following protections set:
 +
      {{#if: {{PROTECTIONLEVEL:edit}}
 +
      | * Edit: {{PROTECTIONLEVEL:edit}}
 +
      }}{{#if: {{PROTECTIONLEVEL:move}}
 +
      | * Move: {{PROTECTIONLEVEL:move}}
 +
      }}{{#if: {{PROTECTIONLEVEL:create}}
 +
      | * Create: {{PROTECTIONLEVEL:create}}
 +
      }}{{#if: {{PROTECTIONLEVEL:upload}}
 +
      | * Upload: {{PROTECTIONLEVEL:upload}}
 +
      }}
 +
    | <br />Unfortunately this file is currently not protected.
 +
    }}
 
   }}
 
   }}
 
| <!-- Not listed as high-risk, so check if protected -->
 
| <!-- Not listed as high-risk, so check if protected -->
   {{#if: {{PROTECTIONLEVEL:edit}} {{PROTECTIONLEVEL:move}} {{PROTECTIONLEVEL:upload}} {{{test2|}}}
+
   {{#if: {{PROTECTIONLEVEL:edit}} {{PROTECTIONLEVEL:move}} {{PROTECTIONLEVEL:create}} {{PROTECTIONLEVEL:upload}} {{{demo2|}}}
 
   | {{fmbox
 
   | {{fmbox
 
     | type = warning
 
     | type = warning
Line 130: Line 206:
 
       }}{{#if: {{PROTECTIONLEVEL:move}}  
 
       }}{{#if: {{PROTECTIONLEVEL:move}}  
 
       | * Move: {{PROTECTIONLEVEL:move}}
 
       | * Move: {{PROTECTIONLEVEL:move}}
 +
      }}{{#if: {{PROTECTIONLEVEL:create}}
 +
      | * Create: {{PROTECTIONLEVEL:create}}
 
       }}{{#if: {{PROTECTIONLEVEL:upload}}  
 
       }}{{#if: {{PROTECTIONLEVEL:upload}}  
 
       | * Upload: {{PROTECTIONLEVEL:upload}}
 
       | * Upload: {{PROTECTIONLEVEL:upload}}
 
       }}
 
       }}
Images are usually locally uploaded and protected here at the English Wikipedia since they are used in an interface message or in some widely used template. Don't delete such images, not even if it is an image that has a backup copy on Commons.
+
Images are usually locally uploaded and protected here at the English Wikipedia since they are used in an interface message or in some widely used template. Don't delete such images, not even if it has a backup copy on Commons. <small>([[Wikipedia talk:Cascade-protected items#About high-risk images|more about this]])</small>
 
     }}
 
     }}
 
   | <!-- Not protected, do nothing -->
 
   | <!-- Not protected, do nothing -->
 
   }}
 
   }}
 
}}<noinclude>
 
}}<noinclude>
 
+
{{documentation}}
 
 
 
</noinclude>
 
</noinclude>

Latest revision as of 17:07, 9 May 2017

Template documentation[view] [edit] [history] [purge]

This is the {{check file on delete}} template.

This template is normally only used by the system, it is called from MediaWiki:Confirmdeletetext and MediaWiki:Filedelete-intro. It displays a warning message when an admin tries to delete a protected file or a known high-risk file.

This template detects all four kinds of protection: edit, move, create and upload protection. It warns even if it is only semi-protection. It then displays a message as seen above this documentation box.

This template also checks against a list of images used in system messages and a list of the most widely used images. If a match is found it displays this message:


If the file is not protected at all and is not a known high-risk image then this template produces no output.

See also

  • {{check page on delete}} – The warning message for normal pages, and for file pages that have no locally uploaded file.