Difference between revisions of "Template:Fooers from Northern Ireland"

From blackwiki
Jump to navigation Jump to search
imported>BrownHairedGirl
(fix display)
imported>BrownHairedGirl
(tweak display)
Line 10: Line 10:
 
-->  }} <!--
 
-->  }} <!--
 
#Supercategory parameter was NOT supplied, so do nothing
 
#Supercategory parameter was NOT supplied, so do nothing
--> |}}''' {{{Profession}}}'''
+
--> |}}''' {{{Profession}}}'''<!--
''and:'' [[:Category:Ireland|Ireland]]: [[:Category:Irish people|People]]: [[:Category:Irish people by occupation|By occupation]]: {{#if:{{{Supercategory|}}} |<!--
+
--><br /><hr><div style="font-style:italic; size:95%">''and:'' [[:Category:Ireland|Ireland]]: [[:Category:Irish people|People]]: [[:Category:Irish people by occupation|By occupation]]: {{#if:{{{Supercategory|}}} |<!--
 
#Supercategory parameter was supplied
 
#Supercategory parameter was supplied
 
     -->  {{#ifexist: Category:Irish {{{Supercategory}}} |<!--
 
     -->  {{#ifexist: Category:Irish {{{Supercategory}}} |<!--
Line 19: Line 19:
 
-->  }} <!--
 
-->  }} <!--
 
#Supercategory parameter was NOT supplied, so do nothing
 
#Supercategory parameter was NOT supplied, so do nothing
--> |}}''' [[:Category:Irish {{#ifeq:{{{Professionkeepcaps|}}} | yes | {{{Profession}}} | {{lcfirst:{{{Profession}}}}}}}|{{{Profession|}}}]]{{COLON}} from NI'''</div>
+
--> |}}''' [[:Category:Irish {{#ifeq:{{{Professionkeepcaps|}}} | yes | {{{Profession}}} | {{lcfirst:{{{Profession}}}}}}}|{{{Profession|}}}]]{{COLON}} from Northern Ireland'''<br /><!--
 +
-->''and:'' [[:Category:United Kingdom|United Kingdom]]: [[:Category:British people|People]]: [[:Category:British people by occupation|By occupation]]: {{#if:{{{Supercategory|}}} |<!--
 +
#Supercategory parameter was supplied
 +
    -->  {{#ifexist: Category:British {{{Supercategory}}} |<!--
 +
    # [[Category:British Supercategory]] exists, so display a link to it
 +
    --> [[:Category:British {{{Supercategory}}}|{{{Supercategory|}}}]]{{COLON}} |<!--
 +
    # [[Category:British Supercategory]] does NOT exist, so do nothing
 +
-->  }} <!--
 +
#Supercategory parameter was NOT supplied, so do nothing
 +
--> |}}''' [[:Category:British {{#ifeq:{{{Professionkeepcaps|}}} | yes | {{{Profession}}} | {{lcfirst:{{{Profession}}}}}}}|{{{Profession|}}}]]{{COLON}} from Northern Ireland'''</div></div>
 
|}
 
|}
  

Revision as of 19:39, 7 January 2017

Classification: People: By occupation: [[:Category:{{{Profession}}}|{{{Profession}}}]]: From Northern Ireland
also: Northern Ireland: People: By occupation: {{{Profession}}}

and: Ireland: People: By occupation: [[:Category:Irish {{{Profession}}}|]]: from Northern Ireland
and: United Kingdom: People: By occupation: [[:Category:British {{{Profession}}}|]]: from Northern Ireland


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

Displays standardized category navigation for people by occupations from Northern Ireland, required by Wikipedia:Naming conventions (categories)#Occupation.

Usage

Example 1
{{Fooers from Northern Ireland |Profession=Writers}}
See Category:Writers from Northern Ireland
Example 2
{{Fooers from Northern Ireland |Profession=Novelists |Supercategory=Writers |Country=Northern Ireland}}
See Category:Novelists from Northern Ireland
Example 3
{{Fooers from Northern Ireland | Profession = DJs |Professionkeepcaps = yes | Supercategory = Electronic musicians }}
See Category:DJs from Northern Ireland
(The Professionkeepcaps= yes is added because "DJs" needs to retain it capitalisation in all contexts)

In most cases, should not be substituted.

Technical deatils

This is a variant of the widely used Template:Fooian fooers. It is for use with the sub-categories of Category:People from Northern Ireland by occupation, which use the format "[Profession] from Northern Ireland", rather than the standard "[Nationality] [profession]".

Adds a pair of standard parent categories:

  • [[Category:Irish Profession| Northern Ireland]]
  • [[Category:British Profession| Northern Ireland]]

(This is because all sub-cats of Category:People from Northern Ireland are parented in the equivalent sub-categories Irish people and British. This reflects the commitment by the governments of the UK, Ireland and Northern Ireland in the Good Friday Agreement to the recognition of both national identities.)

If the "Supercategory" parameter is used, the following parent category will be generated added:

  • [[Category:Supercategory from Northern Ireland|Profession]]

Otherwise, this parent category will be generated:

  • [[Category:People from Northern Ireland by occupation|Profession]]

In all cases. the template adds:

  • [[Category:Profession by nationality|Nationality]]

Self-checking

The template tests for the existence of [[Category:Profession by nationality]] or [[Category:Supercategory by nationality]], and alters its output as follows:

  1. If the "Supercategory" parameter is supplied, but [[Category:Supercategory by nationality]] does not exist, then [[Category:Supercategory]] will be used instead.
  2. When the "Supercategory" parameter is not supplied, the template tests for the existence of [[Category:Profession by nationality]]. If that does not exist, then [[Category:Profession]] will be used instead.

See also