This code:
<?php
$rsCountryDetection = new WA_MySQLi_RS("rsCountryDetection",$connSegufixNew,1);
$rsCountryDetection->setQuery("SELECT c.hide_button, c.country FROM ip2nationCountries c, ip2nation i WHERE i.ip < INET_ATON("' . $_SERVER['REMOTE_ADDR'] . '") AND c.code = i.country ORDER BY i.ip DESC LIMIT 0,1'");
$rsCountryDetection->execute();
?>
should be:
<?php
$rsCountryDetection = new WA_MySQLi_RS("rsCountryDetection",$connSegufixNew,1);
$rsCountryDetection->setQuery("SELECT c.hide_button, c.country FROM ip2nationCountries c, ip2nation i WHERE i.ip < INET_ATON(?) AND c.code = i.country ORDER BY i.ip DESC LIMIT 0,1'");
$rsCountryDetection->bindParam("s", "".($_SERVER['REMOTE_ADDR']) ."", "-1"); //varRemoteAddr
$rsCountryDetection->execute();
?>
<?php
$hide_button = $rsCountryDetection->getColumnVal("hide_button");
$countryName = $rsCountryDetection->getColumnVal("country");
?>