Question

I need to process information received by mail with my DB automatically.

lets say the server received an email for 'X' , and 'X' is indexed in my DB, i want to perform an action on this row in the database.

I'm running an Ubuntu server and php 5.5.

what is the best way of achieving it?

** EDIT **

I know its not PHP alone, I have no problem modifying server variables / doing some modifications.

Was it helpful?

Solution

2 options:

  • if GMail accepts your mail, you can't capture it there. If you have a paid account there, you can set up additional routes for specific emailaddresses to also be delivered to a server under your control (in which case Marc B.'s answer should be followed: configure that other mail server to just pipe the mail to whatever script you want).
  • if you can't do that, or don't want to, just look at the imap extension of PHP, if plays perfectly nice with Google's IMAP interface in my experience.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top