Extension:KML Export/dms2deg

From MediaWiki.org
Jump to: navigation, search
KML Export FeaturesInstallationQuick startHow to useParser functionsSpecial pagesConfiguration

These parser functions convert geographic coordinates in degrees-minutes-seconds notation to degree notation.

Syntax [edit]

{{#lat_dms2deg: degrees | minutes | seconds | hemisphere }}
{{#long_dms2deg: degrees | minutes | seconds | hemisphere }}

Arguments [edit]

degrees
Degrees part of the latitude or longitude coordinate.
minutes
Minutes part of the latitude or longitude coordinate.
seconds
Seconds part of the latitude or longitude coordinate.
hemisphere
A single letter, either N or S for lat_dms2deg, W or E for long_dms2deg.

Returns [edit]

Both functions return the converted decimal degree value.

Example [edit]

{{#lat_dms2deg:22|57|5|S}}
{{#long_dms2deg:43|12|39|W}}

The above wiki markup returns:

-22.951389
-43.210833

See also [edit]