Problem with PHP mail()
am 29.09.2007 05:15:27 von Bucky Kaufman
The built in mail() function for PHP is supposed to return true/false.
Unfortunately, instead of mine returning a false, it crashes with an
"Internal Server Error" message.
Is this a common problem, and can it be fixed through code?
I called my IPP's tech support. The tech thought it was weird, and put in a
service order - but I'm still curious if it's an error I can handle.
Any thoughts?
Re: Problem with PHP mail()
am 29.09.2007 07:27:33 von Michael Fesser
..oO(Sanders Kaufman)
>The built in mail() function for PHP is supposed to return true/false.
>Unfortunately, instead of mine returning a false, it crashes with an
>"Internal Server Error" message.
There should be a more detailed message in the server's error log.
Micha
Re: Problem with PHP mail()
am 04.10.2007 01:55:06 von Manuel Lemos
Hello,
on 09/29/2007 12:15 AM Sanders Kaufman said the following:
> The built in mail() function for PHP is supposed to return true/false.
> Unfortunately, instead of mine returning a false, it crashes with an
> "Internal Server Error" message.
>
> Is this a common problem, and can it be fixed through code?
>
> I called my IPP's tech support. The tech thought it was weird, and put in a
> service order - but I'm still curious if it's an error I can handle.
>
> Any thoughts?
You may want to take a look at this class that comes with wrapper
functions that emulate the mail() function without using it. If you can
use an SMTP server, you can use the smtp_mail() function. If you can run
sendmail or equivalent, you can use sendmail_mail(). Those functions
have the same arguments as mail(), just with a different name.
http://www.phpclasses.org/mimemessage
--
Regards,
Manuel Lemos
Metastorage - Data object relational mapping layer generator
http://www.metastorage.net/
PHP Classes - Free ready to use OOP components written in PHP
http://www.phpclasses.org/