PHP Classes

GeoLocation

Recommend this page to a friend!

      GeoLocation (geoPlugin)  >  All threads  >  GeoLocation  >  (Un) Subscribe thread alerts  
Subject:GeoLocation
Summary:NL
Messages:6
Author:devilsoft
Date:2008-12-12 20:23:40
Update:2008-12-13 17:07:29
 

  1. GeoLocation   Reply   Report abuse  
Picture of devilsoft devilsoft - 2008-12-12 20:23:40
This class isn`t working in the netherlands wy?

  2. Re: GeoLocation   Reply   Report abuse  
Picture of Andy S Andy S - 2008-12-13 11:07:47 - In reply to message 1 from devilsoft
The class and service isn't geographically limited, so there is no reason why it isn't working, except that maybe your IP address isn't in the geoip database.

If you could post an output of what this page says (from the location where you are trying the class), it will help understand why it isn't working for you:
geoplugin.net/php.gp

  3. Re: GeoLocation   Reply   Report abuse  
Picture of devilsoft devilsoft - 2008-12-13 15:35:05 - In reply to message 1 from devilsoft
Is this good?
a:12:{s:14:"geoplugin_city";s:5:"Breda";s:16:"geoplugin_region";s:2:"06";s:18:"geoplugin_areaCode";s:1:"0";s:17:"geoplugin_dmaCode";s:1:"0";s:21:"geoplugin_countryCode";s:2:"NL";s:21:"geoplugin_countryName";s:11:"Netherlands";s:23:"geoplugin_continentCode";s:2:"EU";s:18:"geoplugin_latitude";s:9:"51.566700";s:19:"geoplugin_longitude";s:8:"4.800000";s:22:"geoplugin_currencyCode";s:3:"EUR";s:24:"geoplugin_currencySymbol";s:7:"€";s:27:"geoplugin_currencyConverter";d:0.7838490613999999911953864284441806375980377197265625;}
Thnx for your support

  4. Re: GeoLocation   Reply   Report abuse  
Picture of Andy S Andy S - 2008-12-13 16:38:16 - In reply to message 3 from devilsoft
Yes, that's good (the php serialized array). So you can contact the server ok, and your IP is in the geoip database.

If the class isn't working then (downloaded as is without altering neither the class, nor the example index.php file), it means your PHP installation has neither cURL support nor allow_url_fopen set in php.ini

cURL:
php.net/manual/en/book.curl.php

allow_url_fopen:
php.net/manual/en/filesystem.config ...

  5. Re: GeoLocation   Reply   Report abuse  
Picture of Andy S Andy S - 2008-12-13 16:53:59 - In reply to message 3 from devilsoft
I've modified the class to throw an error if neither cURL support nor allow_url_fopen is set.

This should now test your installation and report why it isn't working.

  6. Re: GeoLocation   Reply   Report abuse  
Picture of devilsoft devilsoft - 2008-12-13 17:07:29 - In reply to message 5 from Andy S
I will try. Thanks for your support.