Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function is_bot(){
- $bots = array(
- 'Googlebot', 'Baiduspider', 'ia_archiver',
- 'R6_FeedFetcher', 'NetcraftSurveyAgent', 'Sogou web spider',
- 'bingbot', 'Yahoo! Slurp', 'facebookexternalhit', 'PrintfulBot',
- 'msnbot', 'Twitterbot', 'UnwindFetchor',
- 'urlresolver', 'Butterfly', 'TweetmemeBot' );
- foreach($bots as $b){
- if( stripos( $_SERVER['HTTP_USER_AGENT'], $b ) !== false ) return true;
- }
- return false;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement