Each time I upgraded to a new version of CountryFlag, I'm suffering the same problems. The JOIN form and even the user search (../users/search) is extremely slow at most times. It's because a script wants to lookup the country from a remote site which is obviously overloaded and which returns a slow response. Very seldom the JOIN form succeeds in registering the user.
I did the following to get rid of these problems :
- open the source ow_plugins/countryflag/bol/service.php and disable all statements in the function detectGeoIP() by putting them between /* and */. So now, there's no lookup, just an empty function which is not troubling anymore.
public static function detectGeoIp() {/* Do not use GEO IP detection, please $_SERVER['REMOTE_ADDR'] = !empty( $_SERVER["HTTP_CF_CONNECTING_IP"] ) ? $_SERVER["HTTP_CF_CONNECTING_IP"] : $_SERVER["REMOTE_ADDR"]; $ipAddress = $_SERVER['REMOTE_ADDR'];// This is an IP for testing//$ipAddress = '83.128.239.152';$result = self::freeGeoIpCall( $ipAddress ); if (!$result)return false;$geoData = json_decode( $result );return $geoData->country_code;*/}