Depends on your mailserver. Most mail servers can redirect incoming
mail to a program, I know sendmail can. In your case just make the first
line of your script #!/path/to/php/bin/php and that should do the trick.
Sorry I don't know how to make sendmail do it, only that you can.
Check the man pages tho, shouldn't be too hard.
Gfunk - http://www.gfunk007.com/
I sense much beer in you. Beer leads to intoxication, intoxication to
hangovers, and hangovers to... suffering.
----- Original Message -----
From: "Ankur Verma" <[EMAIL PROTECTED]>
To: "PHP User Group" <[EMAIL PROTECTED]>
Sent: Saturday, February 03, 2001 5:51 AM
Subject: [PHP] Automatic incoming mail notification
Hello All!
Sorry for this off-topic posting but this is extremely important for me.
I need a php script to be called each time my email mailbox recieves a new
email message. One way is to have a cron job running and get the php script
to check my mailbox every few minutes to see if there are any new emails and
do the needfull if there is one.
But I guess that there should be a way for the mail server to initiate some
action based on the reciept of a new mail in a particular mailbox. I don't
think trhat sites like Yahoo and Hotmail use cron jobs to sense new emails
in a user's mailbox. Another possibility might be that the checking is being
done every few minutes by the client application.
if anyone has any idea about the methodology being followed by Yahoo and
Hotmail, please be kind enough to pass it on. If anyone is aware of a mail
server otr a mailserver addin which would enable automatic notification and
initiaition of script on the reciept of a new email, please pass the info
on.
I am on Redhat 6.2 with cyrus as my mail server and am using PHP4.
Thanks in advance
Ankur Verma
HCL Technologies
A1CD, Sector 16,
Noida
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]