Jamit Software Forum
Welcome, Guest. Please login or register.
July 21, 2018, 05:25:26 pm

Login with username, password and session length
Search:     Advanced search
May 27th, 2009 - Jamit Software Launches the forum today!
3,080 Posts in 791 Topics by 1,435,262 Members
Latest Member: izpvvayhufw
* Home Help Search Login Register
+  Jamit Software Forum
|-+  General Boards
| |-+  General Discussion
| | |-+  Email Me When Google Hits My Site
« previous next »
Pages: [1] Print
Author Topic: Email Me When Google Hits My Site  (Read 45156 times)
jamitmodules
Guest
« on: June 30, 2009, 03:21:44 pm »

Hello,

Would it not be great to get and email with google hits your site. Heres How.

In this short tutorial we will cover how to send yourself an email via a PHP Script when Google spider has visited your site.

The Complete php code is this.

Code:
<?php
if ( strpos$_SERVER[&#39;HTTP_USER_AGENT&#39;], &#39;Googlebot&#39; ) !== false )
{
    
// The email address we want to send the email to
    
$email_address = &#39;CHANGE TO YOUR EMAIL ADDRESS&#39;;

     // Send the email
    
mail($email_address,&#39;Googlebot Visit&#39;, &#39;Googlebot has visited your page: &#39;.$_SERVER[&#39;REQUEST_URI&#39;]);
}
?>




All you need to do is paste just under the </head> tag on the front page and everytime google hits you .... You will receive and email.
Logged
jaffri
Jammers
Sr. Member
*
Posts: 51


« Reply #1 on: August 25, 2009, 12:22:57 pm »

If anyone has tried it, what are the comments?
Logged
Peter
Administrator
Hero Member
*****
Posts: 248



« Reply #2 on: September 10, 2009, 07:02:09 am »

Google hits my site about 300x per day. I sure don't want to be bombed by useless emails.
Logged

SECURE your site BEFORE you wish you had! Use plugins by COLOSSAL MIND!
steve
Jammers
Hero Member
*
Posts: 150


« Reply #3 on: January 15, 2011, 05:07:28 pm »

This is a great idea for someone just starting a job board.

I'm with Peter, though. After your site is established the e-mails could get overwhelming.
Logged
Pages: [1] Print 
« previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.156 seconds with 17 queries.