PHP code example of kipkaev55 / sxgeo
1. Go to this page and download the library: Download kipkaev55/sxgeo 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/ */
kipkaev55 / sxgeo example snippets
use SypexGeo\Reader;
$reader = new Reader('SxGeoCity.dat', 'ru');
var_export($reader->getGeo('127.0.0.1'));
var_export($reader->getGeo('192.168.0.1'));
var_export($reader->getGeo('217.25.213.220'));
bash
curl -sS https://getcomposer.org/installer | php
php composer.phar