Modèle:Location

De Wiklou, le Wiki du Biclou
Aller à : navigation, rechercher
Lieu de la prise de vuelatitude, longitudeVoir cet endroit et d’autres images sur : OpenStreetMap - Google Earthinfo
Documentation icon Template documentation[view] [edit] [history] [purge]

Syntax #1: decimal degrees

Template used for geocoding Commons images, providing camera location using decimal or degrees/minutes/seconds (DMS) syntax. See Commons:Geocoding for more information.

{{Location}} is the main template of the {{Location}}, {{Object location}} and {{Globe location}} family and is supposed to be used to define the coordinates and heading of the location of the camera.

The template automatically sets the following categories: Depending on namespace:

In case of errors:

Usage

{{Location |2= |3= |1= }}

Should be placed directly above or below {{Information}}, {{Artwork}} or other similar template.
Note: some users prefer to include location template(s) into the "Description" field of {{Information}} template in order to group all location information together – objections are in point of graphic design not ideal adjusted for such use. See this and this discussion.

⧼templatedata-doc-params⧽

ParameterDescriptionDefaultStatus
2LongitudeDegrees of Longitude. The sign indicates hemisphere: + (East) and - (West).emptyrequired
3attributesInformation attributes - used to pass to GeoHack server metadata about the coordinates. Apart from heading, this information is not used by {{Location}} template. Attributes have to be in the format field1:value1_field2:value2_field3:value3, etc. The following fields are supported:
  • region:XX-YYY specifies the political region, used to select appropriate map resources. See here for more info.
  • XX is an ISO 3166-1 alpha 2 country code abbreviation, and
  • YYY is a 1-, 2- or 3- characters ISO 3166-2 (see en:ISO 3166-2#Format for details) province/region/state code abbreviation (typically the same as a local postal code abbreviation).
  • heading: indicate the direction in which the camera was pointing. It is given as degree values 0-360 (clockwise with north as 0) or a compass point abbreviation (up to four letters) as defined in Points of the compass. (Example: heading:NW). It should be very similar for both {{Location}} and {{Object location}} templates when used in the same image. For example "heading:N" means that the camera was pointing North when the photograph was taken. In case of {{Object location}} template that might mean that we are looking at a South wall/side of the structure/object.
  • scale:N specifies the desired map scale as 1:N. Since most images are at the lowest scale, the parameter should be given only if values different from the default are desired. See here for more info.
  • dim:<width><units> specifies the width of the object in meters or kilometers (example: dim:120m or dim:10km. Since most images are at the lowest scale, the parameter should be given only if values different from the default are desired. See here for more info.
  • class:object is hard-coded value which will be added automatically to all images to tag this location as the ""object location
emptyoptional
barebare"bare=1" will show only field value without field's name ("Object location")emptyoptional
secondarysecondarysecondary=1 will tag this set of coordinates as secondary. This template calls {{#coordinates:}} parser function, one of the parameters of which is primary vs. secondary label. Primary coordinates define file's camera location and are the default, but each file can only have single primary location tag.emptyoptional
precprecisionBy default the georeference precision is about 0.3 meters or 1/100 of a second on the equator. To show less digits add parameter "prec" with a measurement precisions expressed in meters. For example 40 meter uncertainty would be expressed as "prec=40". At the moment this parameter only affects the display of the coordinates.0.3optional
1LatitudeDegrees of Latitude. The sign indicates hemisphere: + (North) and - (South).emptyrequired

Additional information

The template is intended to be used in the following namespaces: the File namespace

The template is intended to be used by the following user groups: all users

Syntax #2: Degrees/Minutes/Seconds (DMS)

Alternative DMS syntax.

Usage

{{Location |2= |8= |9= |3= |1= |4= |5= |6= |7= }}

⧼templatedata-doc-params⧽

ParameterDescriptionDefaultStatus
2latitude minutesMinutes of Latitudeemptyrequired
8East/West hemisphereLongitude Direction or East/West Hemisphere (W or E)emptyrequired
9attributesInformation attributes - used to pass to GeoHack server metadata about the coordinates. Apart from heading, this information is not used by {{Location}} template. Attributes have to be in the format field1:value1_field2:value2_field3:value3, etc. The following fields are supported:
  • region:XX-YYY specifies the political region, used to select appropriate map resources. See here for more info.
  • XX is an ISO 3166-1 alpha 2 country code abbreviation, and
  • YYY is a 1-, 2- or 3- characters ISO 3166-2 (see en:ISO 3166-2#Format for details) province/region/state code abbreviation (typically the same as a local postal code abbreviation).
  • heading: indicate the direction in which the camera was pointing. It is given as degree values 0-360 (clockwise with north as 0) or a compass point abbreviation (up to four letters) as defined in Points of the compass. (Example: heading:NW). It should be very similar for both {{Location}} and {{Object location}} templates when used in the same image. For example "heading:N" means that the camera was pointing North when the photograph was taken. In case of {{Object location}} template that might mean that we are looking at a South wall/side of the structure/object.
  • scale:N specifies the desired map scale as 1:N. Since most images are at the lowest scale, the parameter should be given only if values different from the default are desired. See here for more info.
  • dim:<width><units> specifies the width of the object in meters or kilometers (example: dim:120m or dim:10km. Since most images are at the lowest scale, the parameter should be given only if values different from the default are desired. See here for more info.
  • class:object is hard-coded value which will be added automatically to all images to tag this location as the ""object location
emptyoptional
3latitude secondsSeconds of Latitudeemptyrequired
1latitude degreesDegrees of Latitudeemptyrequired
4North/South hemisphereLatitude Direction or North/South hemisphere (N or S)emptyrequired
5longitude degreesDegrees of Longitudeemptyrequired
6longitude minutesMinutes of Longitudeemptyrequired
precprecisionBy default the georeference precision is about 0.3 meters or 1/100 of a second on the equator. To show less digits add parameter "prec" with a measurement precisions expressed in meters. For example 40 meter uncertainty would be expressed as "prec=40". At the moment this parameter only affects the display of the coordinates.0.3optional
barebare"bare=1" will show only field value without field's name ("Camera location")emptyoptional
7longitude secondsSeconds of Longitudeemptyrequired

Additional information

The template is intended to be used in the following namespaces: all content namespaces

The template is intended to be used by the following user groups: all users

Relies on:
Module:Coordinates

⧼Seealso⧽

  • Other templates from the family:
  • {{Location}} – used to provide camera location using
  • {{Object location}} – used to provide object location using
  • {{Globe location}} – used to provide object location on other globes, like Moon, Mars, etc.
  • Related templates

All translations at Module:I18n/coordinates

Examples

Syntax #1
Code {{Location|34.02427|-116.15830|region:DE-NI_scale:10000}}
Produces
Lieu de la prise de vue34° 01′ 27,37″ N, 116° 09′ 29,88″ OVoir cet endroit et d’autres images sur : OpenStreetMap - Google Earthinfo
Syntax #2
Code {{Location|34|1|27.37|N|116|9|29.88|W|...}}
Produces
Lieu de la prise de vue34° 01′ 27,37″ N, 116° 09′ 29,88″ O  225°Voir cet endroit et d’autres images sur : OpenStreetMap - Google Earthinfo
Main syntax
Code {{Location|34|1|27.37|N|116|9|29.88|W|...}}
Produces
Lieu de la prise de vue34° 01′ 27,37″ N, 116° 09′ 29,88″ O  225°Voir cet endroit et d’autres images sur : OpenStreetMap - Google Earthinfo