Hi Guys... new to php... just signed up for CloudFlare and trying to use IP Geolocation
any help would be appreciated... the goal is for the selected countries to show maintenance message. Otherwise show the content of the page
this is what I have but its not working...
<?php
$country_code = $_SERVER["HTTP_CF_IPCOUNTRY"];
if ($country_code=="FR") { echo "Site Under Maintenance"; } elseif ($country_code=="UK") { echo "Site Under Maintenance"; } elseif ($country_code=="US") { echo "Site Under Maintenance"; }
else {
}
?>
Thanks in advance