Difference between revisions of "Template:Csdcheck/doc"

From blackwiki
Jump to navigation Jump to search
imported>Mr. Stradivarius
(use clear:right on the wikitable)
imported>Trialpears
 
(6 intermediate revisions by 5 users not shown)
Line 1: Line 1:
 +
{{documentation subpage}}
 
{{lua|Module:Csdcheck}}
 
{{lua|Module:Csdcheck}}
  
 
{| class="wikitable" style="float:right; clear:right; font-size:90%; margin:5px"
 
{| class="wikitable" style="float:right; clear:right; font-size:90%; margin:5px"
 
|-
 
|-
!Code!!Template!!Description!!all!!tag!!notice
+
!Code!!Template!!Description!!tag!!notice
 
|-
 
|-
|G1||{{tl|db-nonsense}}||[[Wikipedia:Patent nonsense|Patent nonsense]]||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|G1||{{tl|db-nonsense}}||[[Wikipedia:Patent nonsense|Patent nonsense]]||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|G2||{{tl|db-test}}||Test pages||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|G2||{{tl|db-test}}||Test pages||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|G3||{{tl|db-vandalism}}||Vandalism||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|G3||{{tl|db-vandalism}}||Vandalism||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|G4||{{tl|db-repost}}||Previously deleted by consensus||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|G4||{{tl|db-repost}}||Previously deleted by consensus||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|G5||{{tl|db-banned}}||Posts by banned user||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
+
|G5||{{tl|db-banned}}||Posts by banned user||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|G6||{{tl|db-maintenance}}||Housekeeping||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
+
|G6||{{tl|db-maintenance}}||Housekeeping||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|G7||{{tl|db-author}}||Request by page author||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
+
|G7||{{tl|db-author}}||Request by page author||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|G8||{{tl|db-g8}}||Talk page of or redir to deleted page||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
+
|G8||{{tl|db-g8}}||Talk page of or redir to deleted page||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|G9|| -- || Office actions ||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
+
|G9|| -- || Office actions ||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|G10||{{tl|db-attack}}||Attack page||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|G10||{{tl|db-attack}}||Attack page||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|G11||{{tl|db-spam}}||Blatant promotion||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|G11||{{tl|db-spam}}||Blatant promotion||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|G12||{{tl|db-copyvio}}||Obvious copyright infringement||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|G12||{{tl|db-copyvio}}||Obvious copyright infringement||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|G13||{{tl|db-afc}}||Abandoned [[WP:AFC|Articles for creation]] submission||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|G13||{{tl|db-afc}}||Abandoned [[WP:AFC|Articles for creation]] submission||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|A1||{{tl|db-nocontext}}||Can't determine subject||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|G14||{{tl|db-disambig}}||Unnecessary disambiguation pages||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|A2||{{tl|db-foreign}}||From another Wikipedia||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|A1||{{tl|db-nocontext}}||Can't determine subject||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|A3||{{tl|db-nocontent}}||Empty or no useful content||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|A2||{{tl|db-foreign}}||From another Wikipedia||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|A5||{{tl|db-transwiki}}||Already been transwikied||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|A3||{{tl|db-nocontent}}||Empty or no useful content||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|A7||{{tl|db-a7}}||No claim of significance||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|A5||{{tl|db-transwiki}}||Already been transwikied||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|A9||{{tl|db-album}}||Album with no claim of significance||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|A7||{{tl|db-a7}}||No claim of significance||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|A10||{{tl|db-same}}||Duplicates an existing article||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|A9||{{tl|db-album}}||Album with no claim of significance||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|A11||{{tl|db-madeup}}||Obviously invented||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|A10||{{tl|db-same}}||Duplicates an existing article||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|F1||{{tl|db-redundantimage}}||Duplicates an existing image||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|A11||{{tl|db-madeup}}||Obviously invented||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|F2||{{tl|db-noimage}}||Corrupt or empty image||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|F1||{{tl|db-redundantimage}}||Duplicates an existing image||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|F3||{{tl|db-noncom}}||Media with unacceptable license||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|F2||{{tl|db-noimage}}||Corrupt or empty image||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|F4||{{tl|db-unksource}}||Media with unknown source||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
+
|F3||{{tl|db-noncom}}||Media with unacceptable license||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|F5||{{tl|db-unfree}}||Non-free license not used in articles||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
+
|F4||{{tl|db-unksource}}||Media with unknown source||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|F6||{{tl|db-norat}}||Fair use rationale needed||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
+
|F5||{{tl|db-f5}}||Non-free license not used in articles||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|F7||{{tl|db-badfairuse}}||Inappropriate fair use||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|F6||{{tl|db-norat}}||Fair use rationale needed||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|F8||{{tl|db-nowcommons}}||Moved to commons||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
+
|F7||{{tl|db-badfairuse}}||Inappropriate fair use||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|F9||{{tl|db-filecopyvio}}||Image copyright infringement||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|F8||{{tl|db-nowcommons}}||Moved to commons||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|F10||{{tl|db-badfiletype}}||Unused media of unsupported type||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|F9||{{tl|db-filecopyvio}}||Image copyright infringement||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|F11||{{tl|db-nopermission}}||Missing evidence of permission||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
+
|F10||{{tl|db-badfiletype}}||Unused media of unsupported type||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|C1||{{tl|db-catempty}}||Empty category||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|F11||{{tl|db-nopermission}}||Missing evidence of permission||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|C2||{{tl|cfr-speedy}}||Renaming/merging of category||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
+
|C1||{{tl|db-catempty}}||Empty category||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|U1||{{tl|db-userreq}}||Requested by user||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
+
|C2||{{tl|cfr-speedy}}||Renaming/merging of category||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|U2||{{tl|db-nouser}}||Non-existent user||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
+
|U1||{{tl|db-userreq}}||Requested by user||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|U3||{{tl|db-gallery}}||User non-free image gallery||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|U2||{{tl|db-nouser}}||Non-existent user||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|R2||{{tl|db-rediruser}}||Cross-namespace redirect||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}  
+
|U3||{{tl|db-gallery}}||User non-free image gallery||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|-
 
|-
|R3||{{tl|db-redirtypo}}||Implausible redirect||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}  
+
|R2||{{tl|db-rediruser}}||Cross-namespace redirect||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}  
 
|-
 
|-
|T2||{{tl|db-policy}}||Mis-states policy||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|R3||{{tl|db-redirtypo}}||Implausible redirect||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}  
 
|-
 
|-
|T3||{{tl|db-t3}}||Duplication/hardcoded cases||{{Color|Green|'''Yes'''}}||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
+
|R4||{{tl|db-redircom}}||File namespace redirect that shadows a Commons file or redirect||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}  
 
|-
 
|-
|P1||{{tl|db-p1}}||Would be speedyable if an article||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|T3||{{tl|db-t3}}||Duplication/hardcoded cases||{{Color|Red|'''No'''}}||{{Color|Red|'''No'''}}
 
|-
 
|-
|P2||{{tl|db-emptyportal}}||Portal with too few articles||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
+
|P1||{{tl|db-p1}}||Would be speedyable if an article||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 +
|-
 +
|P2||{{tl|db-emptyportal}}||Portal with too few articles||{{Color|Green|'''Yes'''}}||{{Color|Green|'''Yes'''}}
 
|}
 
|}
  
Line 150: Line 153:
  
 
=== See also ===
 
=== See also ===
* [[Module:Csdcheck]], the [[WP:LUA|Lua]] module that is called by this template
+
* [[Module:Csdcheck]], the [[WP:LUA|Lua]] module that is called by this template.
  
<includeonly>
+
<includeonly>{{Sandbox other|
<!-- Categories and interwikis go here: -->
+
| <!-- Categories here: -->
 
[[Category:If-then-else templates]]
 
[[Category:If-then-else templates]]
</includeonly>
+
}}</includeonly>

Latest revision as of 11:44, 14 July 2020

Code Template Description tag notice
G1 {{db-nonsense}} Patent nonsense Yes Yes
G2 {{db-test}} Test pages Yes Yes
G3 {{db-vandalism}} Vandalism Yes Yes
G4 {{db-repost}} Previously deleted by consensus Yes Yes
G5 {{db-banned}} Posts by banned user Yes No
G6 {{db-maintenance}} Housekeeping Yes No
G7 {{db-author}} Request by page author Yes No
G8 {{db-g8}} Talk page of or redir to deleted page Yes No
G9 -- Office actions No No
G10 {{db-attack}} Attack page Yes Yes
G11 {{db-spam}} Blatant promotion Yes Yes
G12 {{db-copyvio}} Obvious copyright infringement Yes Yes
G13 {{db-afc}} Abandoned Articles for creation submission Yes Yes
G14 {{db-disambig}} Unnecessary disambiguation pages Yes Yes
A1 {{db-nocontext}} Can't determine subject Yes Yes
A2 {{db-foreign}} From another Wikipedia Yes Yes
A3 {{db-nocontent}} Empty or no useful content Yes Yes
A5 {{db-transwiki}} Already been transwikied Yes Yes
A7 {{db-a7}} No claim of significance Yes Yes
A9 {{db-album}} Album with no claim of significance Yes Yes
A10 {{db-same}} Duplicates an existing article Yes Yes
A11 {{db-madeup}} Obviously invented Yes Yes
F1 {{db-redundantimage}} Duplicates an existing image Yes Yes
F2 {{db-noimage}} Corrupt or empty image Yes Yes
F3 {{db-noncom}} Media with unacceptable license Yes Yes
F4 {{db-unksource}} Media with unknown source No No
F5 {{db-f5}} Non-free license not used in articles No No
F6 {{db-norat}} Fair use rationale needed No No
F7 {{db-badfairuse}} Inappropriate fair use Yes Yes
F8 {{db-nowcommons}} Moved to commons Yes No
F9 {{db-filecopyvio}} Image copyright infringement Yes Yes
F10 {{db-badfiletype}} Unused media of unsupported type Yes Yes
F11 {{db-nopermission}} Missing evidence of permission No No
C1 {{db-catempty}} Empty category Yes Yes
C2 {{cfr-speedy}} Renaming/merging of category No No
U1 {{db-userreq}} Requested by user Yes No
U2 {{db-nouser}} Non-existent user Yes No
U3 {{db-gallery}} User non-free image gallery Yes Yes
R2 {{db-rediruser}} Cross-namespace redirect Yes Yes
R3 {{db-redirtypo}} Implausible redirect Yes Yes
R4 {{db-redircom}} File namespace redirect that shadows a Commons file or redirect Yes Yes
T3 {{db-t3}} Duplication/hardcoded cases No No
P1 {{db-p1}} Would be speedyable if an article Yes Yes
P2 {{db-emptyportal}} Portal with too few articles Yes Yes

This template checks whether any given input strings are valid speedy deletion (CSD) criteria. If any of the input strings are valid, the template outputs "yes"; if none of them are valid, it does not output anything. Valid CSD criteria take the form of a letter plus a number, e.g. "G6" or "A7" (see the table to the right for a list). This template accepts both uppercase and lowercase letters as valid, so both "G3" and "g3" would return "yes". It accepts any number of input strings. It is also possible to compare the input strings to a custom selection of CSD criteria.

Usage

Basic usage

{{csdcheck|string to be compared}}

Checking multiple strings

{{csdcheck|string1|string2|string3|string4|etc.}}

Using a specific subset of CSD criteria

{{csdcheck|string1|string2|string3|string4|set=desired subset of CSD criteria}}

Searching for specific CSD criteria

{{csdcheck|string1|string2|string3|string4|crit1=first criteria to search for|crit2=second criteria to search for|etc.}}

This template can be either substituted or transcluded.

Parameters

  • set:- This parameter can take the value "all", "tag", or "notice". A value of "all" returns "yes" for all valid CSD criteria; a value of "tag" returns "yes" for all criteria supported by the template {{db-multiple}}; and a value of "notice" returns "yes" for all criteria supported by the template {{db-notice-multiple}}. The default value is "all". See the table to the right for which criteria are supported for each value of the parameter.
  • crit1, crit2, crit3, etc.:- These parameters are used to check for specific speedy deletion criteria. It is possible to search for both single and multiple criteria. For example, if |crit1=g1 is specified, the template will search to see if any of the input strings match CSD criterion G1, and if they do it will output "yes". If |crit1=g11 and |crit=a7 are both specified, the template will search to see if any of the input strings match either CSD criteria G11 or A7, and if there are any matches it will output "yes". You can add any number of criteria. If any of the "crit" parameters are specified then the "set" parameter has no effect on the template's output.

Examples

Input Output
{{csdcheck|a7}} yes
{{csdcheck|foo}}
{{csdcheck|g9}} yes
{{csdcheck|g9|set=tag}}
{{csdcheck|foo|bar|g5}} yes
{{csdcheck|foo|bar|g5|set=notice}}
{{csdcheck|g1|crit1=g1}} yes
{{csdcheck|g1|crit1=g2}}
{{csdcheck|foo|crit1=foo}}
{{csdcheck|g9|crit1=g9|set=tag}} yes
{{csdcheck|g1|g2|g3|g4|crit1=a7}}
{{csdcheck|g1|g2|g3|g4|crit1=g3}} yes
{{csdcheck|g1|g2|g3|g4|crit1=a7|crit2=a10|crit3=g2}} yes

See also