Difference between revisions of "Template:GNIS/doc"
imported>Zyxw (update documentation and examples) |
imported>Zyxw (Make documentation for this template only (other templates now have their own documentation), include TemplateData) |
||
| Line 1: | Line 1: | ||
{{Documentation subpage}} | {{Documentation subpage}} | ||
<!-- Categories go at the bottom of this page and interwikis go in Wikidata. --> | <!-- Categories go at the bottom of this page and interwikis go in Wikidata. --> | ||
| − | |||
| − | + | [[Template:GNIS]] generates an external link to a Feature Detail Report from the [[Geographic Names Information System]] (GNIS), published by the [[United States Geological Survey]] (USGS). The link is displayed as "U.S. Geological Survey Geographic Names Information System: ''Name''", where ''Name'' is either the Wikipedia article name (<code><nowiki>{{</nowiki>PAGENAME}}</code>) or an optionally specified name. | |
| − | [[Template:GNIS]] generates an external link to a GNIS | + | |
| + | == Usage == | ||
| + | |||
| + | The only required parameter is the GNIS Feature ID number (optionally, this parameter can be named <code>id</code>). The template then uses the Wikipedia article name as part of the [[anchor text]]. | ||
<nowiki>{{</nowiki>GNIS|''ID''}} | <nowiki>{{</nowiki>GNIS|''ID''}} | ||
<nowiki>{{</nowiki>GNIS|id=''ID''}} | <nowiki>{{</nowiki>GNIS|id=''ID''}} | ||
| − | + | If desired, a feature name other than the article name can be specified in a second unnamed parameter (optionally, this can be named <code>name</code>). This can be used if the article name contains disambiguation or when the GNIS feature name is different than the article name. | |
<nowiki>{{</nowiki>GNIS|''ID''|''Name''}} | <nowiki>{{</nowiki>GNIS|''ID''|''Name''}} | ||
<nowiki>{{</nowiki>GNIS|id=''ID''|name=''Name''}} | <nowiki>{{</nowiki>GNIS|id=''ID''|name=''Name''}} | ||
| − | + | For GNIS features in Antarctica, add <code>|type=antarid</code>. | |
| − | |||
| − | |||
| − | |||
| − | |||
| − | + | <nowiki>{{</nowiki>GNIS|''ID''|type=antarid}} | |
| − | < | + | <nowiki>{{</nowiki>GNIS|id=''ID''|type=antarid}} |
| − | < | ||
| − | |||
| − | |||
| − | |||
<nowiki>{{</nowiki>GNIS|''ID''|''Name''|type=antarid}} | <nowiki>{{</nowiki>GNIS|''ID''|''Name''|type=antarid}} | ||
<nowiki>{{</nowiki>GNIS|id=''ID''|name=''Name''|type=antarid}} | <nowiki>{{</nowiki>GNIS|id=''ID''|name=''Name''|type=antarid}} | ||
| − | + | == TemplateData == | |
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | + | {{TemplateDataHeader}} | |
| − | {{ | + | <templatedata>{ |
| + | "description": "This template generates an external link to a Feature Detail Report from the Geographic Names Information System (GNIS), published by the United States Geological Survey (USGS). The link is displayed as 'U.S. Geological Survey Geographic Names Information System: Name', where Name is either the Wikipedia article name ({{PAGENAME}}) or an optionally specified name.", | ||
| + | "params": { | ||
| + | "1": { | ||
| + | "label": "ID", | ||
| + | "aliases": ["id"], | ||
| + | "description": "GNIS Feature ID, a number without leading zeros.", | ||
| + | "type": "number", | ||
| + | "default": "", | ||
| + | "required": true | ||
| + | }, | ||
| + | "2": { | ||
| + | "label": "Name", | ||
| + | "aliases": ["name"], | ||
| + | "description": "GNIS Feature Name or other descriptive text. If not given it defaults to the Wikipedia article name", | ||
| + | "type": "number", | ||
| + | "default": "{{PAGENAME}}", | ||
| + | "required": false | ||
| + | }, | ||
| + | "type": { | ||
| + | "label": "Type", | ||
| + | "description": "Use the value 'antarid' (type=antarid) for features in Antarctica.", | ||
| + | "type": "string", | ||
| + | "default": "", | ||
| + | "required": false | ||
| + | } | ||
| + | }}</templatedata> | ||
| − | + | == Instructions == | |
| − | |||
| − | + | # Go to the [http://geonames.usgs.gov/apex/f?p=gnispq GNIS Feature Search] page. | |
| − | + | # Search for the name, location, and/or class of the feature desired, e.g., to find a mountain called 'Mt. Foo', type '<code>mount foo</code>' in the Feature Name box and select 'Summit' from the Feature Class list. | |
| − | + | # Copy the 'ID' number for the desired feature and insert it into the <code><nowiki>{{</nowiki>GNIS|...}}</code> template. | |
| + | # The latitude and longitude can also be copied and used in the {{tlx|coord}} template, inserting the '{{para}}' vertical bar between degrees, minutes, seconds, and direction, e.g.: 441613N 0711812W → <code><nowiki>{{</nowiki>coord|44|16|13|N|071|18|12|W|region:US}}</code> | ||
| − | + | == Examples == | |
| − | |||
| − | |||
| − | = | + | URL: http://geonames.usgs.gov/apex/f?p=gnispq:3:::NO::P3_FID:871352 |
| − | + | * ''Usage:'' <code><nowiki>{{</nowiki>GNIS | 871352 | Mount Washington }}</code> | |
| + | ** ''Result:'' {{GNIS | 871352 | Mount Washington }} | ||
| + | * ''Usage:'' <code><nowiki>{{</nowiki>GNIS |id= 871352 |name= Mount Washington }}</code> | ||
| + | ** ''Result:'' {{GNIS |id= 871352 |name= Mount Washington }} | ||
| − | + | URL: http://geonames.usgs.gov/apex/f?p=gnispq:5:::NO::P5_ANTAR_ID:2828 | |
| − | + | * ''Usage:'' <code><nowiki>{{</nowiki>GNIS | 2828 | Clarke Glacier |type= antarid }}</code> | |
| − | + | ** ''Result:'' {{GNIS | 2828 | Clarke Glacier |type= antarid }} | |
| + | * ''Usage:'' <code><nowiki>{{</nowiki>GNIS |id= 2828 |name= Clarke Glacier |type= antarid }}</code> | ||
| + | ** ''Result:'' {{GNIS |id= 2828 |name= Clarke Glacier |type= antarid }} | ||
| − | + | == See also == | |
| − | |||
| − | |||
| − | + | Other GNIS templates: | |
| − | + | * [[Template:GNIS 2]] – link with anchor text "[1]" or "''Name''" | |
| − | + | * [[Template:GNIS 3]] – link as bare [[URL]] only, without anchor text | |
| − | + | * [[Template:GNIS 4]] – link with GNIS Feature ID number as the anchor text | |
| − | + | * [[Template:Cite GNIS]] – link using the {{tl|Cite web}} template, for use as a reference | |
| − | |||
| − | |||
| − | | | ||
| − | }} | ||
| − | |||
| − | + | List of pages linking to [[Special:Linksearch/geonames.usgs.gov|geonames.usgs.gov]]: | |
| − | + | * [[Special:Linksearch/geonames.usgs.gov/apex/f?p=gnispq]] (current format) | |
| − | | | + | * [[Special:Linksearch/geonames.usgs.gov/pls/gnispublic/f?p=gnispq]] (old format) |
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | + | Similar templates: | |
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
* [[Template:Mountain index row]] | * [[Template:Mountain index row]] | ||
* [[Template:Cite cgndb]] (Canada) | * [[Template:Cite cgndb]] (Canada) | ||
** [[Template:Cite bcgnis]] (British Columbia) | ** [[Template:Cite bcgnis]] (British Columbia) | ||
* [[Template:GPN]] (Gazetteer of Planetary Nomenclature) | * [[Template:GPN]] (Gazetteer of Planetary Nomenclature) | ||
| + | |||
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox|| | <includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox|| | ||
<!-- Categories go here, and interwikis go in Wikidata --> | <!-- Categories go here, and interwikis go in Wikidata --> | ||
[[Category:U.S. Government external link templates]] | [[Category:U.S. Government external link templates]] | ||
}}</includeonly> | }}</includeonly> | ||
Revision as of 21:33, 9 May 2014
| This is a documentation subpage for Template:GNIS. It contains usage information, categories and other content that is not part of the original template page. |
Template:GNIS generates an external link to a Feature Detail Report from the Geographic Names Information System (GNIS), published by the United States Geological Survey (USGS). The link is displayed as "U.S. Geological Survey Geographic Names Information System: Name", where Name is either the Wikipedia article name ({{PAGENAME}}) or an optionally specified name.
Usage
The only required parameter is the GNIS Feature ID number (optionally, this parameter can be named id). The template then uses the Wikipedia article name as part of the anchor text.
{{GNIS|ID}}
{{GNIS|id=ID}}
If desired, a feature name other than the article name can be specified in a second unnamed parameter (optionally, this can be named name). This can be used if the article name contains disambiguation or when the GNIS feature name is different than the article name.
{{GNIS|ID|Name}}
{{GNIS|id=ID|name=Name}}
For GNIS features in Antarctica, add |type=antarid.
{{GNIS|ID|type=antarid}}
{{GNIS|id=ID|type=antarid}}
{{GNIS|ID|Name|type=antarid}}
{{GNIS|id=ID|name=Name|type=antarid}}
TemplateData
TemplateData for GNIS
This template generates an external link to a Feature Detail Report from the Geographic Names Information System (GNIS), published by the United States Geological Survey (USGS). The link is displayed as 'U.S. Geological Survey Geographic Names Information System: Name', where Name is either the Wikipedia article name ({{PAGENAME}}) or an optionally specified name.
| Parameter | Description | Type | Status | |
|---|---|---|---|---|
| ID | 1 id | GNIS Feature ID, a number without leading zeros.
| Number | required |
| Name | 2 name | GNIS Feature Name or other descriptive text. If not given it defaults to the Wikipedia article name
| Number | optional |
| Type | type | Use the value 'antarid' (type=antarid) for features in Antarctica.
| String | optional |
Instructions
- Go to the GNIS Feature Search page.
- Search for the name, location, and/or class of the feature desired, e.g., to find a mountain called 'Mt. Foo', type '
mount foo' in the Feature Name box and select 'Summit' from the Feature Class list. - Copy the 'ID' number for the desired feature and insert it into the
{{GNIS|...}}template. - The latitude and longitude can also be copied and used in the
{{coord}}template, inserting the '|' vertical bar between degrees, minutes, seconds, and direction, e.g.: 441613N 0711812W →{{coord|44|16|13|N|071|18|12|W|region:US}}
Examples
URL: http://geonames.usgs.gov/apex/f?p=gnispq:3:::NO::P3_FID:871352
- Usage:
{{GNIS | 871352 | Mount Washington }} - Usage:
{{GNIS |id= 871352 |name= Mount Washington }}
URL: http://geonames.usgs.gov/apex/f?p=gnispq:5:::NO::P5_ANTAR_ID:2828
- Usage:
{{GNIS | 2828 | Clarke Glacier |type= antarid }} - Usage:
{{GNIS |id= 2828 |name= Clarke Glacier |type= antarid }}
See also
Other GNIS templates:
- Template:GNIS 2 – link with anchor text "[1]" or "Name"
- Template:GNIS 3 – link as bare URL only, without anchor text
- Template:GNIS 4 – link with GNIS Feature ID number as the anchor text
- Template:Cite GNIS – link using the {{Cite web}} template, for use as a reference
List of pages linking to geonames.usgs.gov:
- Special:Linksearch/geonames.usgs.gov/apex/f?p=gnispq (current format)
- Special:Linksearch/geonames.usgs.gov/pls/gnispublic/f?p=gnispq (old format)
Similar templates:
- Template:Mountain index row
- Template:Cite cgndb (Canada)
- Template:Cite bcgnis (British Columbia)
- Template:GPN (Gazetteer of Planetary Nomenclature)