On 25 Mar 2005 10:31:09 -0800, "siliconmike" <si*********@yahoo.com> wrote:
How to set up my PC (or what tools do I need) so that when any email
comes to the server, a php script is automatically run to parse the
email ?
I've never done this before. Later I would like to transfer my website
to a Linux box, but I'm using a PC currently to develop the site.
Details are welcome. In fact I have no concepts about which program or
"server" is supposed to receive email, then how would that program
"pass" the email as a parameter to a php script ? Is a pop server
involved in this process ? If yes, the what is the most popular one
(which is available for both pc and linux) ? And so on..
Look up "procmail".
Normally there will be an SMTP mail server running on wherever your email
account is. This will receive emails, and write them to your mailbox. procmail
can be used to run programs in response to emails arriving.
POP3 comes into the picture when you want to get at your mailbox from a remote
machine.
If you're developing on your PC, then it's unlikely that PC is going to be
where emails arrive, i.e. it won't be running the receiving end of an SMTP
server. You could use "fetchmail" to regularly fetch email locally, "procmail"
to run them through PHP, and run a local POP3 server if you then also want to
read the same emails with a POP client.
Also look up Cygwin - this is a particularly useful bit of software, as it
gives you a Unix-like environment on Windows. You'll then be able to work with
the same tools that'd be available later when you move it to Linux.
--
Andy Hassall / <an**@andyh.co.uk> / <http://www.andyh.co.uk>
<http://www.andyhsoftware.co.uk/space> Space: disk usage analysis tool