RE: [PHP] mail function fails
| From: | Shrout, Ryan | Date: | Mon, 02 Jul 2001 13:29:39 +0000 |
| Subject: | RE: [PHP] mail function fails | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-55829@lists.php.net to get a copy of this message | ||
I tried that in this format:
if ( mail("bsmall@ikmc.com", "Quote Request", $message, "From:
mail@somewhere.com\nX-Mailer: PHP/" . phpversion()) ) {
echo "Email sent!";
} else {
echo "Email NOT sent!";
}
and still get the Email NOT sent and no emails go anywhere. Is there
another solution? How about a way to get an error message of some kind?
Ryan
-----Original Message-----
From: Tim Taubert [mailto:timtaubert@web.de]
Sent: Monday, July 02, 2001 9:09 AM
To: PHP Mailingliste
Subject: RE: [PHP] mail function fails
hey ryan try something like this
mail("bsmall@ikmc.com", "Quote Request", $message, "From:
mail@somewhere.com\nX-Mailer: PHP/" . phpversion());
hope this helps
cya tim
---------------------------------------------------------------------
Tim Taubert | timtaubert@web.de | http://www.shogunat.com/rg/
---------------------------------------------------------------------
-----Original Message-----
From: Shrout, Ryan [mailto:Rshrout@krauss-maffeicorp.com]
Sent: Monday, July 02, 2001 3:01 PM
To: 'php-general@lists.php.net'
Subject: [PHP] mail function fails
I am having a problem with the PHP mail() function. Here is the code:
if (mail ("bsmall@ikmc.com", "Quote Request", $message)) {
echo "Email sent!";
} else {
echo "Email NOT sent!";
}
Everytime, I receive the Email NOT sent message and the email isn't sent.
However, from the console on the same machine, I can run the mail command:
mail bsmall@ikmc.com and send an email just fine.
Any ideas as to what could be wrong?
I am using the latest PHP version and am running Red Hat Linux 7.1
Ryan Shrout
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
For additional commands, e-mail: php-general-help@lists.php.net
To contact the list administrators, e-mail: php-list-admin@lists.php.net
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
For additional commands, e-mail: php-general-help@lists.php.net
To contact the list administrators, e-mail: php-list-admin@lists.php.net