or download this
$dbh->do("INSERT INTO Site_Visit SET firstVisit = NOW(), lastPage = ?,
+ firstPage = ?, IP = ?, userAgent = ?, orsa = ?, orta = ?, Person_idP
+erson = ?", undef,
$ENV{'REQUEST_URI'}, $ENV{'REQUEST_URI'}, $ENV{'REMOTE_ADDR'
+}, $ENV{'HTTP_USER_AGENT'}, $cookie{'orsa'}, $data{'orta'}, $user)
unless $ENV{'HTTP_USER_AGENT'} =~ /bot/i or $ENV{'HTTP_USER_AGEN
+T'} =~ /facebook/i or $ENV{'HTTP_USER_AGENT'} =~ /dataprovider/i;