Autor: Tim Jackson Data: A: exim-users Assumpte: Re: [Exim] forwarding whole mail to php script
Hi KISember, on Tue, 30 Dec 2003 16:29:35 +0100 you wrote:
> I want to process a mail with a php script immediately as it comes.
> I couldn't find a variable containing the message
> (I have listed all the variables available with there value). I also
> couldn't get it via pop3 because it doesn't appear in the INBOX.
> Does anyone know how to forward the whole mail to the script?
The mail is already passed to the script, but not as a variable. You need
to read from stdin.
$MyMail = fopen('php://stdin','r');
...
(you can also use the STDIN constant in PHP >=4.3)