Commit 57c620ac authored by noplanman's avatar noplanman Committed by GitHub

Merge pull request #86 from diasporg/fixone

fix map
parents fe62158f e53a9410
......@@ -158,14 +158,12 @@ while ($row = pg_fetch_assoc($result)) {
$location = geoip_record_by_name($ip);
_debug('Location', $location, true);
if ($location) {
$country = !empty($location['country_code']) ? iconv('UTF-8', 'UTF-8//IGNORE', $location['country_code']) : null;
$city = !empty($location['city']) ? iconv('UTF-8', 'UTF-8//IGNORE', $location['city']) : null;
$state = !empty($location['region']) ? iconv('UTF-8', 'UTF-8//IGNORE', $location['region']) : null;
$lat = !empty($location['latitude']) ? $location['latitude'] : null;
$long = !empty($location['longitude']) ? $location['longitude'] : null;
}
$country = !empty($location['country_code']) ? iconv('UTF-8', 'UTF-8//IGNORE', $location['country_code']) : null;
$city = !empty($location['city']) ? iconv('UTF-8', 'UTF-8//IGNORE', $location['city']) : null;
$state = !empty($location['region']) ? iconv('UTF-8', 'UTF-8//IGNORE', $location['region']) : null;
$lat = !empty($location['latitude']) ? $location['latitude'] : null;
$long = !empty($location['longitude']) ? $location['longitude'] : null;
echo $newline;
$statslastdate = date('Y-m-d H:i:s');
$ping = curl_init();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment