Siteme Google bot harici hiçkimse giremesin
1
●500
- 30-12-2013, 10:19:40htaccess ile (denemedim ancak çalışır diye düşünüyorum)
php ile aşağıdaki kodu kullanarak google botları tespit edebilirsin.Alıntı
<?php function botDetect() { $bots_list=array( "Google"=>"Googlebot", //"Yahoo"=>"Slurp", //"Bing"=>"bingbot" /*You can add more bot here*/ ); $regexp='/'. implode("|", $bots_list).'/'; $ua=$_SERVER['HTTP_USER_AGENT']; if(preg_match($regexp, $ua,$matches)) { $bot= array_search($matches[0], $bots_list); return $bot; } else { return false; } } ?>