Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Daniel's robot detector
- $status = true;
- if (isset($this->request->server['HTTP_USER_AGENT'])) {
- $robots = explode("\n", trim($this->config->get('config_robots')));
- foreach ($robots as $robot) {
- if (strpos($this->request->server['HTTP_USER_AGENT'], trim($robot)) !== false) {
- $status = false;
- break;
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement