Parsing e-mail problem

From: Date: Wed, 30 Aug 2000 17:23:11 +0000
Subject: Parsing e-mail problem
Groups: php.general 
Request: Send a blank email to php-general+get-14368@lists.php.net to get a copy of this message
Hi all, I need to parse incoming e-mails - for a certain address - with a php scripts to perform some checks and redirections. I have a forward to a PHP script in /etc/aliases. This is what I do: $fp = fopen("/dev/stdin","r"); $message = fread($fp,512000); since filesize() does not work here I have to impose a fix max size. All works fine without attachments while if the message has an attachment (60 K in my tests) I got this error back: ----- Transcript of session follows ----- Content-type: text/html <br> <b>Fatal error</b>: Maximum execution time exceeded in <b>www/htdocs/rentingpeugeot/admin/recivemail.php3</b> on line <b>23</b><br> 554 "|www/cgi-bin/php www/htdocs/rentingpeugeot/admin/recivemail.php3"... unknown mailer error 1 Line 23 is the line following: $message = fread($fp,512000); in my script. If I comment that line the error appears on the first useful line regardless of the content. I also changed the max execution time on the fly but it still looks like the script dies while trying to read from STDIN. Any idea? Thanks in advance, Gianluca -- ALBASOFTWARE C/ Aribau 70 - 5º 1ª 08011 Barcelona (Spain) Tel. +34 93454009 - +34 934549324 Fax. +34 934541979 @@ ICQ 47323154 @@ webmaster@albasoftware.com http://www.albasoftware.com http://www.phpauction.org http://www.gianlucabaldo.com

« previous php.general (#14368) next »