library swiss-coordinates
Converting swiss coordinates to Lat/Long global coordinates.
nadar/swiss-coordinates
Converting swiss coordinates to Lat/Long global coordinates.
- Sunday, April 29, 2018
- by nadar
- Repository
- 1 Watchers
- 0 Stars
- 86 Installations
- PHP
- 0 Dependents
- 0 Suggesters
- 0 Forks
- 0 Open issues
- 2 Versions
- 4 % Grown
Convert WGS (Word Geodetic System) coordinates into CH (Swiss-Coordinates) and vice versa.
Wrapper class with composer support based on http://www.swisstopo.admin.ch/internet/swisstopo/de/home/products/software/products/skripts.html, (*1)
- Lat/Long = Latitude And Longitude
- WGS = Word Geodetic System
- Lat = Y-Axis
- Long = X-Axis
Example swiss coordinates:
- Rigi: Y = 679520, X = 212273
- ZĂŒrich-Seebach: Y = 684592, X = 252857
Installation
composer require nadar/swiss-coordinates
Usage example:
use swisscoordinates\Converter;
echo Converter::CHtoWGSlat(679520, 212273); // 47.056709
echo Converter::CHtoWGSlong(679520, 212273); // 8.485306