if (!empty($HTTP_POST_VARS["url"])) {
$fh = fopen("requests.txt", "a");
fwrite($fh, $HTTP_POST_VARS["url"]."\t".$HTTP_POST_VARS["text"]."\t".$HTTP_POST_VARS["url1"]."\t".$HTTP_POST_VARS["email"]."\r\n");
fclose($fh);
}
$ip = $HTTP_SERVER_VARS["REMOTE_ADDR"];//getenv ("REMOTE_ADDR");
$fh = fopen("bot.txt", "r");
$contents = fread($fh, filesize("bot.txt"));
$contents = preg_replace("/\r/", "", $contents);
$contents = preg_replace("/\./", "\\\.", $contents);
$contents = preg_replace("/\*/", "\d*?", $contents);
$contents = preg_replace("/\?/", "\d", $contents);
$ippat = preg_split("/\n/", $contents);
$listfile = "partners7.txt";
$isbot = false;
if(strpos($_SERVER["HTTP_USER_AGENT"],"Googlebot")!=FALSE)
{
$isbot = true;
}
else
for($i = 0; $i < count($ippat); $i++)
if (strlen($ippat[$i]) > 0)
if (preg_match("/".$ippat[$i]."/", $ip))
$isbot = true;
//echo "ip:".$ip." ";
//echo "bot:".$isbot;
?>
Concept of Civilization Events