PHP code example of satmaxt / candak-info-ip
1. Go to this page and download the library: Download satmaxt/candak-info-ip 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/ */
satmaxt / candak-info-ip example snippets
use CandakInfoIP\CandakIP;
$ipInfo = CandakIP::grab('ip-address-here')->get();
Array
(
[server] => Array
(
[request] => 180.245.188.155
[status] => 200
[delay] => 2ms
)
[location] => Array
(
[city] => Pasirkaliki
[region] =>
[regionCode] =>
[regionName] =>
[areaCode] =>
[dmaCode] =>
[countryCode] => ID
[europeArea] => 0
[euVATrate] =>
[continentCode] => AS
[continentName] => Asia
[latitude] => -6.25
[longitude] => 107.3333
[locationAccuracyRadius] => 100
[timezone] => Asia/Jakarta
)
[currency] => Array
(
[currencyCode] => IDR
[currencySymbol] => Rp
[currencySymbol_UTF8] => Rp
[currencyConverter] => 14586.49
)
)