Forum Replies Created

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter Moddinu

    (@moddinu)

    Hey guys after further debugging I found the issue for some reason after reinstalling the plugin I got set as a subscriber. So when I reinstalled it I did not have access to the the yop poll.

    So make sure your an admin user in the site otherwise yop poll won’t all access to modify polls.

    Thread Starter Moddinu

    (@moddinu)

    So after some further testing , It seems like a database issue, as when I restore an older version of the database the menu is shown in the main blog.

    Thread Starter Moddinu

    (@moddinu)

    After further investigation I found that the the problem was with the service used to get the users ip so I change the code as follows:

    $url = 'https://www.geoplugin.net/xml.gp?ip='.$ip;
    $ch = curl_init($url);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    $cdata = curl_exec($ch);
    curl_close($ch);
    $carr = simplexml_load_string($cdata);
    
    $return = $countries["{$carr->geoplugin_countryCode}"];
    return $return;

    Note: If you are using the plugin on a localhost machine the ip would be 127.0.0.1 therefore the service will return a 404 error. so you may want to add an if statement to set a default county code if the ip is 127.0.0.1.

Viewing 3 replies - 1 through 3 (of 3 total)