PHP code example of kotenarok / open-location-code
1. Go to this page and download the library: Download kotenarok/open-location-code library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
kotenarok / open-location-code example snippets
use OpenLocationCode\OpenLocationCode;
// encode
var_dump(OpenLocationCode::encode(48.41, 34.81));
// decode (return area array)
var_dump(OpenLocationCode::decode("44870000+"));