Difference between revisions of "Template:Decade in US state category"

From blackwiki
Jump to navigation Jump to search
imported>BrownHairedGirl
m (Protected "Template:Decade in US state category": Highly visible template: Used in over 1000 category pages, which are wholly dependant on this template ([Edit=Require template editor access] (indefinite) [Move=Require template editor access] (indefinite)))
imported>BrownHairedGirl
 
Line 7: Line 7:
 
               # Not a valid page
 
               # Not a valid page
 
           -->{{Error|ERROR. [[Template:Decade in US state category]] is for use only on pages with a title of the form "Category:YYY0s in Foo", where YYYY0s is a 4-digit decade and "Foo" is the name of a state of the United States.}}<!--
 
           -->{{Error|ERROR. [[Template:Decade in US state category]] is for use only on pages with a title of the form "Category:YYY0s in Foo", where YYYY0s is a 4-digit decade and "Foo" is the name of a state of the United States.}}<!--
           -->[[Category:Template Decade in US state category on invalid page]]
+
           -->[[Category:Errors reported by other category header templates]]
 
       -->|<!--
 
       -->|<!--
 
               # A valid page
 
               # A valid page
Line 18: Line 18:
 
     # Not a category
 
     # Not a category
 
   -->|{{Error|message=ERROR.  [[Template:Decade in US state category]] is for use only on category pages}}<!--
 
   -->|{{Error|message=ERROR.  [[Template:Decade in US state category]] is for use only on category pages}}<!--
   -->[[Category:Template Decade in US state category on invalid page]]<!--
+
   -->[[Category:Errors reported by other category header templates]]<!--
 
-->}}</includeonly><noinclude>
 
-->}}</includeonly><noinclude>
 
<!-- Add categories and interwikis to the /doc subpage, please, not here! -->  
 
<!-- Add categories and interwikis to the /doc subpage, please, not here! -->  
 
{{Documentation}}
 
{{Documentation}}
 
</noinclude>
 
</noinclude>

Latest revision as of 03:18, 2 September 2020

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

Purpose

This template is intended to be used on decade in US state categories (for example, Category:1930s in Oregon or Category:1970s in Wyoming). It creates a "timeline" style table of links to categories for adjacent years before or after it in the same decade.

Syntax

{{Decade in US state category}}

No parameters are needed, and none are available

Error-checking

The template checks that the page:

  1. is a category
  2. has a title of the form "YYY0s in Foo"

If either of those conditions is not met, an error message is displayed and no other output is generated, but the page is added to a tracking category:

Note that this category is also used by many other category header templates

Purge page to update totals

Template:U.S. state by year category header templates