Template:Town site: Difference between revisions

From Wikishire
Jump to navigation Jump to search
RB (talk | contribs)
No edit summary
RB (talk | contribs)
No edit summary
 
(5 intermediate revisions by the same user not shown)
Line 1: Line 1:
{{#ifeq:{{{1}}}|0||{{#switch:{{{1}}}
{{#ifeq:{{{1}}}|0||{{#switch:{{{1}}}
|Aberdeen
|Aberdeen
|Bath
|Belfast
|Belfast
|Birmingham
|Birmingham
|Brighton
|Bristol
|Bristol
|Cambridge
|Cambridge
Line 8: Line 10:
|Cardiff
|Cardiff
|the City of London
|the City of London
|Chester
|Cork
|Cork
|Dublin
|Dublin
Line 15: Line 18:
|Glasgow
|Glasgow
|Leeds
|Leeds
|Leicester
|Lincoln
|Liverpool
|Liverpool
|London
|London
|Londonderry
|Londonderry
|Manchester
|Manchester
|Newcastle-upon-Tyne
|Newcastle upon Tyne
|Norwich
|Norwich
|Oxford
|Oxford

Latest revision as of 20:32, 18 March 2023

{{Town cats}} is part of a system intended to allow certain infoboxes to categorise pages not just by county but also by town. It is anticipated that this will apply only to certain major cities and famous towns.

The two templates working together are:

  • {{Town site}}: This determines whether the town or city name fed from the infobox is one of the listed cities or towns. If the list of towns with their own categories should be lengthened or shortened, it will be in this template.
  • {{Town cats}}: This creates the appropriate category, if the infobox 'type' is one which can generate a town category. If the number of in-town categories should be change, it will be in this template.

All is dependent however on the Infobox template: if it is to be capable of generating an in-town category it must have the coding to extract the town name and to feed it to {{Town site}}. One would not have such coding in, for example {{Infobox waterfall}}, but for {{Infobox building}} it could.

[create] Template documentation