Jump to content

Extension:CoordinateConversion

From mediawiki.org
MediaWiki extensions manual
CoordinateConversion
Release status: beta
Implementation Parser function , Special page
Description Allows the conversion of WGS84 coordinates to various national coordinate systems
Author(s) Wouter Rademaker (Egeltalk)
Latest version 0.8.2 (2022-12-11)
MediaWiki
License GNU General Public License 2.0
Download
Example Scoutpedia.nl - nl.scoutwiki.org

The CoordinateConversion extension allows the conversion of WGS84 coordinates to the national coordinate systems of:

  • The Netherlands - Rijksdriehoekscoördinaten, RD
  • France - Lambert93
  • Belgium - Lambert2008
  • Suisse - CH1903 (LV03) and CH1903+ (LV95)
  • Finland - TM35FIN, extended UTM zone 35N
  • Canada - MTM, SCOPQ
  • Great Britain - OSGB36
  • Republic Ireland and North Ireland - Irish Transverse Mercator
  • Luxembourg - LUREF
  • Conversion of (WGS84) geographical coordinates to Universal Transverse Mercator (UTM)
  • Conversion of (WGS84) geographical coordinates to other coordinate reference system using https://epsg.io

Internal functions for

  • transverse Mercator projection (WGS84)
  • transverse Mercator projection (other mapdata)
  • Lambert projection
  • Datumtransformation

Special page "CCTest" (Special:CCTest) provided by this extension gives an overview of example use cases and their expected results.

Usage

[edit]
  • {{#deg2dms: latitude , longitude }} geographic coordinates in decimal degree notation to degrees-minutes-seconds notation
  • {{#lat_deg2dms: latitude }}
  • {{#long_deg2dms: longitude }}
  • {{#lat_dms2deg: degrees | minutes | seconds | hemisphere }} geographic coordinates in degrees-minutes-seconds notation to decimal degree notation
  • {{#long_dms2deg: degrees | minutes | seconds | hemisphere }}
  • {{#wgs84_2utm: latitude | longitude | zone (optional) }} - WGS84 Latitude/Longitude to UTM
  • {{#wgs84_2rd: latitude | longitude }} - WGS84 Latitude/Longitude to RD - the Netherlands
  • {{#wgs84_2lb93: latitude | longitude }} - WGS84 Latitude/Longitude to Lambert93 - France
  • {{#wgs84_2lb08: latitude | longitude }} - WGS84 Latitude/Longitude to Lambert2008 - Belgium
  • {{#wgs84_2ch03: latitude | longitude }} - WGS84 Latitude/Longitude to CH1903 - Suisse
  • {{#wgs84_2ch03p: latitude | longitude }} - WGS84 Latitude/Longitude to CH1903+ - Suisse
  • {{#wgs84_2tm35fin: latitude | longitude }} - WGS84 Latitude/Longitude to TM35FIN = extended UTM zone 35N - Finland
  • {{#wgs84_2mtm: latitude | longitude | zone (optional) }} - WGS84 Latitude/Longitude to MTM - Canada (SCOPQ in Quebec)
  • {{#wgs84_2osgb: latitude | longitude }} - WGS84 Latitude/Longitude to OSGB36 - Great Britain
  • {{#wgs84_2itm: latitude | longitude }} - WGS84 Latitude/Longitude to Irish Transverse Mercator- Republic Ireland and North Ireland
  • {{#wgs84_2luref: latitude | longitude }} - WGS84 Latitude/Longitude to LUREF - Luxembourg
  • {{#wgs84_2epsg:latitude , longitude , Height|target coordinate reference system}} - WGS84 Latitude/Longitude to other coordinate reference system using https://epsg.io

Installation

[edit]
  • Download and place the file(s) in a directory called CoordinateConversion in your extensions/ folder.
  • Add the following code at the bottom of your LocalSettings.php file:
    wfLoadExtension( 'CoordinateConversion' );
    
  • Yes Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.

See also

[edit]