Template:Geographic location/doc: Difference between revisions
m 1 revision |
m 1 revision imported |
||
| (One intermediate revision by one other user not shown) | |||
| Line 1: | Line 1: | ||
{{ | {{Documentation subpage}} | ||
{{high-use| 23,000+ | Wikipedia talk:High-risk templates }} | |||
{{high-use| | <!--Categories where indicated at the bottom of this page, please; interwikis at Wikidata (see [[Wikipedia:Wikidata]])--> | ||
== Usage == | == Usage == | ||
<pre> | <pre> | ||
{{Geographic location | {{Geographic location | ||
|Centre = | | Centre = | ||
|North = | | North = | ||
|Northeast = | | Northeast = | ||
|East = | | East = | ||
|Southeast = | | Southeast = | ||
|South = | | South = | ||
|Southwest = | | Southwest = | ||
|West = | | West = | ||
|Northwest = | | Northwest = | ||
}} | }} | ||
</pre> | </pre> | ||
Or: | |||
<pre> | |||
{{Geographic location | |||
| Centre = | |||
| N = | |||
| NE = | |||
| E = | |||
| SE = | |||
| S = | |||
| SW = | |||
| W = | |||
| NW = | |||
}} | |||
</pre> | |||
The template is coded to handle the American spelling "center". It first looks for a value in "Centre", then in "Center"; it defaults to the "( | This template provides for a convenient compass-based navigational aid for articles about communities. It allows you to display the communities surrounding the subject of your article. | ||
While this template may be useful for cities, it certainly is redundant for continents, countries and other large geographical areas like states, provinces and islands. In the lead paragraphs of those types of articles, all surrounding countries and features are invariably stated and linked and there's usually a map in the infobox too. | |||
The only '''required''' field is "'''Centre'''"; the template defaults to an "(enter location)" in the centre of the box message if nothing is entered here (''see note below''). The fields ''Northwest (NW)'', ''North (N)'', ''Northeast (NE)'', ''West (W)'', ''East (E)'', ''Southwest (SW)'', ''South (S)'', and ''Southeast (SE)'' are optional. They will be hidden when not used; when values are entered for the relevant parameters, the fields will automatically appear. (Normal Wiki markup can be used in the fields, such as links, colours, and bold/italics.) | |||
The template is coded to handle the American spelling "center". It first looks for a value in "Centre", then in "Center"; it defaults to the "(enter location)" message if both are left blank. | |||
In order to ensure consistent usage, the following guidelines are suggested: | In order to ensure consistent usage, the following guidelines are suggested: | ||
* Use same-level jurisdictions or equivalent in the directional fields as in the centre. For instance, when using this template for a province, show adjacent provinces; when using it for a municipality, show adjacent municipalities; when using it for unincorporated places, show adjacent unincorporated communities; etc. | * Use same-level jurisdictions or equivalent in the directional fields as in the centre. For instance, when using this template for a province, show adjacent provinces; when using it for a municipality, show adjacent municipalities; when using it for unincorporated places, show adjacent unincorporated communities; etc. | ||
* When a municipality borders an international, provincial, or state boundary, try to use a municipality in that adjacent jurisdiction rather than the jurisdiction itself. | * When a municipality borders an international, provincial, or state boundary, try to use a municipality in that adjacent jurisdiction rather than the jurisdiction itself. | ||
* Geographical features such as oceans, | * Geographical features such as oceans, rivers, lakes, and mountains should be in ''italics'' to differentiate them. | ||
* Avoid cluttering the template with too much detail; it is a | * Avoid cluttering the template with too much detail; it is a navigational guide to provide links to adjacent locations, not a map. | ||
* Don't use flag icons for every link, see [[MOS:INFOBOXFLAG]]. They don't add value and are unnecessarily distracting. | |||
== | ===Placement in article=== | ||
*[[WP:LAYOUTNAV]] specifies that Navboxes, including geography boxes such as this one, are placed after the External links section. | |||
== Examples == | |||
Here is an example for [[Ottawa]] (capital of Canada) demonstrating the guidelines above: | Here is an example for [[Ottawa]] (capital of Canada) demonstrating the guidelines above: | ||
<pre> | |||
{{Geographic location | |||
| Centre = Ottawa | |||
| North = [[Pontiac, Quebec|Pontiac]], [[Gatineau]] ([[Quebec]])<br>''[[Ottawa River]]'' | |||
| Northeast = [[Lochaber-Partie-Ouest, Quebec|Lochaber-Partie-Ouest]] ([[Quebec]])<br>''[[Ottawa River]]'' | |||
| East = [[Clarence-Rockland, Ontario|Clarence-Rockland]] | |||
| Southeast = [[Russell, Ontario|Russell]], [[The Nation, Ontario|The Nation]] | |||
| South = [[North Grenville, Ontario|North Grenville]], [[North Dundas, Ontario|North Dundas]] | |||
| Southwest = [[Merrickville-Wolford, Ontario|Merrickville-Wolford]] | |||
| West = [[Mississippi Mills, Ontario|Mississippi Mills]]<br>[[Beckwith, Ontario|Beckwith]]<br>[[Montague, Ontario|Montague]] | |||
| Northwest = [[Arnprior, Ontario|Arnprior]] | |||
}} | |||
</pre> | |||
produces: | |||
{{Geographic location | {{Geographic location | ||
|Centre = Ottawa | | Centre = Ottawa | ||
|North = | | North = [[Pontiac, Quebec|Pontiac]], [[Gatineau]] ([[Quebec]])<br>''[[Ottawa River]]'' | ||
| Northeast = [[Lochaber-Partie-Ouest, Quebec|Lochaber-Partie-Ouest]] ([[Quebec]])<br>''[[Ottawa River]]'' | |||
|East = [[Clarence-Rockland, Ontario|Clarence-Rockland]] | | East = [[Clarence-Rockland, Ontario|Clarence-Rockland]] | ||
|Southeast = [[Russell, Ontario|Russell]], [[The Nation, Ontario|The Nation]] | | Southeast = [[Russell, Ontario|Russell]], [[The Nation, Ontario|The Nation]] | ||
|South = [[North Grenville, Ontario|North Grenville]], [[North Dundas, Ontario|North Dundas]] | | South = [[North Grenville, Ontario|North Grenville]], [[North Dundas, Ontario|North Dundas]] | ||
|Southwest = [[Merrickville-Wolford, Ontario|Merrickville-Wolford]] | | Southwest = [[Merrickville-Wolford, Ontario|Merrickville-Wolford]] | ||
|West = [[Mississippi Mills, Ontario|Mississippi Mills]]<br>[[Beckwith, Ontario|Beckwith]]<br>[[Montague, Ontario|Montague]] | | West = [[Mississippi Mills, Ontario|Mississippi Mills]]<br>[[Beckwith, Ontario|Beckwith]]<br>[[Montague, Ontario|Montague]] | ||
|Northwest = [[Arnprior, Ontario|Arnprior]] | | Northwest = [[Arnprior, Ontario|Arnprior]] | ||
}} | |||
Not all directions necessarily need to be filled: | |||
<pre> | |||
{{Geographic location | |||
| Centre = Knokke-Heist | |||
| N = ''[[North Sea]]'' | |||
| E = [[Sluis]] ([[Netherlands|NL]]-[[Zeeland|ZE]]) | |||
| S = [[Damme]] | |||
| W = [[Bruges]] | |||
}} | |||
</pre> | |||
produces: | |||
{{Geographic location | |||
| Centre = Knokke-Heist | |||
| N = ''[[North Sea]]'' | |||
| E = [[Sluis]] ([[Netherlands|NL]]-[[Zeeland|ZE]]) | |||
| S = [[Damme]] | |||
| W = [[Bruges]] | |||
}} | |||
== Title option == | |||
An optional title can be added, use <code>|title=</code>. For example, this is useful where 2 boxes are needed: | |||
{{Geographic location | |||
| title = '''Eastern part''' (includes the poblacion) | |||
| Centre = Pakil | |||
| North = [[Pangil, Laguna|Pangil]] | |||
| East = [[Real, Quezon]] | |||
| South = [[Paete, Laguna|Paete]] | |||
| West = ''[[Laguna de Bay]]'' | |||
}} | |||
{{Geographic location | |||
| title = '''Western part''' (includes barangays Banilan, Kabulusan, Casa Real, Casinsin, Dorado, Matikiw) | |||
| Centre = Pakil | |||
| North = [[Mabitac, Laguna|Mabitac]] / [[Pangil, Laguna|Pangil]] | |||
| East = ''[[Laguna de Bay]]'' | |||
| South = [[Jalajala, Rizal]] | |||
| West = [[Jalajala, Rizal]] | |||
| Northwest = [[Pililla, Rizal]] | |||
}} | }} | ||
| Line 45: | Line 128: | ||
{{Geographic location|noicon=yes | {{Geographic location|noicon=yes | ||
|Centre = Ottawa | | Centre = Ottawa | ||
|North = | | North = [[Pontiac, Quebec|Pontiac]], [[Gatineau]] ([[Quebec]])<br>''[[Ottawa River]]'' | ||
| Northeast = [[Lochaber-Partie-Ouest, Quebec|Lochaber-Partie-Ouest]] ([[Quebec]])<br>''[[Ottawa River]]'' | |||
|East = [[Clarence-Rockland, Ontario|Clarence-Rockland]] | | East = [[Clarence-Rockland, Ontario|Clarence-Rockland]] | ||
|Southeast = [[Russell, Ontario|Russell]], [[The Nation, Ontario|The Nation]] | | Southeast = [[Russell, Ontario|Russell]], [[The Nation, Ontario|The Nation]] | ||
|South = [[North Grenville, Ontario|North Grenville]], [[North Dundas, Ontario|North Dundas]] | | South = [[North Grenville, Ontario|North Grenville]], [[North Dundas, Ontario|North Dundas]] | ||
|Southwest = [[Merrickville-Wolford, Ontario|Merrickville-Wolford]] | | Southwest = [[Merrickville-Wolford, Ontario|Merrickville-Wolford]] | ||
|West = [[Mississippi Mills, Ontario|Mississippi Mills]]<br>[[Beckwith, Ontario|Beckwith]]<br>[[Montague, Ontario|Montague]] | | West = [[Mississippi Mills, Ontario|Mississippi Mills]]<br>[[Beckwith, Ontario|Beckwith]]<br>[[Montague, Ontario|Montague]] | ||
|Northwest = [[Arnprior, Ontario|Arnprior]] | | Northwest = [[Arnprior, Ontario|Arnprior]] | ||
}} | }} | ||
== Nesting the box == | == Nesting the box == | ||
By default, the width of the geographic location box is 80%, and is forced to float below any left or right floating elements. To allow the box to nest next to an infobox, image, or other floating element, | By default, the width of the geographic location box is 80%, and is forced to float below any left or right floating elements. To allow the box to nest next to an infobox, image, or other floating element, enter {{para|width|auto}} on the first line. | ||
{{Infobox | {{Infobox | ||
| above = | | above = Example infobox | ||
| label1 = Label | | label1 = Label | ||
| data1 = Data | | data1 = Data | ||
| label2 = Label | | label2 = Label | ||
| data2 = Data | | data2 = Data | ||
| label3 = Label | | label3 = Label | ||
| data3 = Data | | data3 = Data | ||
}} | }} | ||
{{Geographic location|width=auto | {{Geographic location|width=auto | ||
|Centre = Ottawa | | Centre = Ottawa | ||
|North = | | North = [[Pontiac, Quebec|Pontiac]], [[Gatineau]] ([[Quebec]])<br>''[[Ottawa River]]'' | ||
| Northeast = [[Lochaber-Partie-Ouest, Quebec|Lochaber-Partie-Ouest]] ([[Quebec]])<br>''[[Ottawa River]]'' | |||
|East = [[Clarence-Rockland, Ontario|Clarence-Rockland]] | | East = [[Clarence-Rockland, Ontario|Clarence-Rockland]] | ||
|Southeast = [[Russell, Ontario|Russell]], [[The Nation, Ontario|The Nation]] | | Southeast = [[Russell, Ontario|Russell]], [[The Nation, Ontario|The Nation]] | ||
|South = [[North Grenville, Ontario|North Grenville]], [[North Dundas, Ontario|North Dundas]] | | South = [[North Grenville, Ontario|North Grenville]], [[North Dundas, Ontario|North Dundas]] | ||
|Southwest = [[Merrickville-Wolford, Ontario|Merrickville-Wolford]] | | Southwest = [[Merrickville-Wolford, Ontario|Merrickville-Wolford]] | ||
|West = [[Mississippi Mills, Ontario|Mississippi Mills]]<br>[[Beckwith, Ontario|Beckwith]]<br>[[Montague, Ontario|Montague]] | | West = [[Mississippi Mills, Ontario|Mississippi Mills]]<br>[[Beckwith, Ontario|Beckwith]]<br>[[Montague, Ontario|Montague]] | ||
|Northwest = [[Arnprior, Ontario|Arnprior]] | | Northwest = [[Arnprior, Ontario|Arnprior]] | ||
}} | }} | ||
<includeonly> | == Tracking category == | ||
[[Category:Geography and place | * {{clc|Geographic location template using undocumented parameters}} | ||
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox | | | |||
<!--Categories below this line, please; interwikis at Wikidata--> | |||
[[Category:Geography and place navigational boxes]] | |||
[[Category:Exclude in print]] | [[Category:Exclude in print]] | ||
</includeonly> | }}</includeonly> | ||
Latest revision as of 21:03, 10 August 2017
| This is a documentation subpage for Template:Geographic location. It may contain usage information, categories and other content that is not part of the original template page. |
| Warning | This template is used on 23,000+ pages and changes may be widely noticed. Test changes in the template's /sandbox or /testcases subpages, or in your own user subpage. Consider discussing changes at Wikipedia talk:High-risk templates before implementing them. |
Usage
{{Geographic location
| Centre =
| North =
| Northeast =
| East =
| Southeast =
| South =
| Southwest =
| West =
| Northwest =
}}
Or:
{{Geographic location
| Centre =
| N =
| NE =
| E =
| SE =
| S =
| SW =
| W =
| NW =
}}
This template provides for a convenient compass-based navigational aid for articles about communities. It allows you to display the communities surrounding the subject of your article.
While this template may be useful for cities, it certainly is redundant for continents, countries and other large geographical areas like states, provinces and islands. In the lead paragraphs of those types of articles, all surrounding countries and features are invariably stated and linked and there's usually a map in the infobox too.
The only required field is "Centre"; the template defaults to an "(enter location)" in the centre of the box message if nothing is entered here (see note below). The fields Northwest (NW), North (N), Northeast (NE), West (W), East (E), Southwest (SW), South (S), and Southeast (SE) are optional. They will be hidden when not used; when values are entered for the relevant parameters, the fields will automatically appear. (Normal Wiki markup can be used in the fields, such as links, colours, and bold/italics.)
The template is coded to handle the American spelling "center". It first looks for a value in "Centre", then in "Center"; it defaults to the "(enter location)" message if both are left blank.
In order to ensure consistent usage, the following guidelines are suggested:
- Use same-level jurisdictions or equivalent in the directional fields as in the centre. For instance, when using this template for a province, show adjacent provinces; when using it for a municipality, show adjacent municipalities; when using it for unincorporated places, show adjacent unincorporated communities; etc.
- When a municipality borders an international, provincial, or state boundary, try to use a municipality in that adjacent jurisdiction rather than the jurisdiction itself.
- Geographical features such as oceans, rivers, lakes, and mountains should be in italics to differentiate them.
- Avoid cluttering the template with too much detail; it is a navigational guide to provide links to adjacent locations, not a map.
- Don't use flag icons for every link, see MOS:INFOBOXFLAG. They don't add value and are unnecessarily distracting.
Placement in article
- WP:LAYOUTNAV specifies that Navboxes, including geography boxes such as this one, are placed after the External links section.
Examples
Here is an example for Ottawa (capital of Canada) demonstrating the guidelines above:
{{Geographic location
| Centre = Ottawa
| North = [[Pontiac, Quebec|Pontiac]], [[Gatineau]] ([[Quebec]])<br>''[[Ottawa River]]''
| Northeast = [[Lochaber-Partie-Ouest, Quebec|Lochaber-Partie-Ouest]] ([[Quebec]])<br>''[[Ottawa River]]''
| East = [[Clarence-Rockland, Ontario|Clarence-Rockland]]
| Southeast = [[Russell, Ontario|Russell]], [[The Nation, Ontario|The Nation]]
| South = [[North Grenville, Ontario|North Grenville]], [[North Dundas, Ontario|North Dundas]]
| Southwest = [[Merrickville-Wolford, Ontario|Merrickville-Wolford]]
| West = [[Mississippi Mills, Ontario|Mississippi Mills]]<br>[[Beckwith, Ontario|Beckwith]]<br>[[Montague, Ontario|Montague]]
| Northwest = [[Arnprior, Ontario|Arnprior]]
}}
produces:
| Adjacent places of Geographic location/doc | ||||
|---|---|---|---|---|
| Arnprior | Pontiac, Gatineau (Quebec) Ottawa River |
Lochaber-Partie-Ouest (Quebec) Ottawa River |
File:Compass rose pale.svg | |
| Mississippi Mills Beckwith Montague |
File:Pfeil oben.svg | Clarence-Rockland | ||
| ||||
| File:Pfeil unten.svg | ||||
| Merrickville-Wolford | North Grenville, North Dundas | Russell, The Nation | ||
Not all directions necessarily need to be filled:
{{Geographic location
| Centre = Knokke-Heist
| N = ''[[North Sea]]''
| E = [[Sluis]] ([[Netherlands|NL]]-[[Zeeland|ZE]])
| S = [[Damme]]
| W = [[Bruges]]
}}
produces:
| Adjacent places of Geographic location/doc | ||||
|---|---|---|---|---|
| North Sea | File:Compass rose pale.svg | |||
| Bruges | File:Pfeil oben.svg | Sluis (NL-ZE) | ||
| ||||
| File:Pfeil unten.svg | ||||
| Damme | ||||
Title option
An optional title can be added, use |title=. For example, this is useful where 2 boxes are needed:
| Eastern part (includes the poblacion) | ||||
|---|---|---|---|---|
| Pangil | File:Compass rose pale.svg | |||
| Laguna de Bay | File:Pfeil oben.svg | Real, Quezon | ||
| ||||
| File:Pfeil unten.svg | ||||
| Paete | ||||
| Western part (includes barangays Banilan, Kabulusan, Casa Real, Casinsin, Dorado, Matikiw) | ||||
|---|---|---|---|---|
| Pililla, Rizal | Mabitac / Pangil | File:Compass rose pale.svg | ||
| Jalajala, Rizal | File:Pfeil oben.svg | Laguna de Bay | ||
| ||||
| File:Pfeil unten.svg | ||||
| Jalajala, Rizal | ||||
Suppressing the compass icons
By default, the geographic location box includes compass icons on the left and right side of the box. To remove these icons, and increase the amount of space available for useful content, use |noicon=yes.
| Adjacent places of Geographic location/doc | ||||
|---|---|---|---|---|
| Arnprior | Pontiac, Gatineau (Quebec) Ottawa River |
Lochaber-Partie-Ouest (Quebec) Ottawa River | ||
| Mississippi Mills Beckwith Montague |
File:Pfeil oben.svg | Clarence-Rockland | ||
| ||||
| File:Pfeil unten.svg | ||||
| Merrickville-Wolford | North Grenville, North Dundas | Russell, The Nation | ||
Nesting the box
By default, the width of the geographic location box is 80%, and is forced to float below any left or right floating elements. To allow the box to nest next to an infobox, image, or other floating element, enter |width=auto on the first line.
| Example infobox | |
|---|---|
| Label | Data |
| Label | Data |
| Label | Data |
| Adjacent places of Geographic location/doc | ||||
|---|---|---|---|---|
| Arnprior | Pontiac, Gatineau (Quebec) Ottawa River |
Lochaber-Partie-Ouest (Quebec) Ottawa River |
File:Compass rose pale.svg | |
| Mississippi Mills Beckwith Montague |
File:Pfeil oben.svg | Clarence-Rockland | ||
| ||||
| File:Pfeil unten.svg | ||||
| Merrickville-Wolford | North Grenville, North Dundas | Russell, The Nation | ||
Tracking category
