|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2002-01-09 17:10 UTC] jberall at yahoo dot com
The mail() function doesn't work properly.
Every so often it does send mail.
I tried putting the php.ini in the c:\php\php.ini instead of the c:\winnt\php.ini but that didn't help.
I've been at it a while and I've found no solutions on the web yet, while other people have encountered the same issue.
PHP.INI has a valid SMTP = mail.pnang.com and sendmail_from = jberall@yahoo.com.
The code
mail("jberall@yahoo.com", "My Subject", "Line 1\nLine 2\nLine 3");
And the birthday one from the manual.
Again the frustrating part is it worked last night. My outlook works perfectly with the same SMTP.
Thanks,
Jonathan
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Oct 25 10:00:01 2025 UTC |
I have the same problem using php 4.2, windows 2000 server iis5. I resolve the problem using \r\n not \n for the break line. Example: mail("cleilton_ce@hotmail.com", "My Subject", "Line 1\nLine 2\nLine 3"); This code results in a server error Correct code: $email = mail("cleilton_ce@hotmail.com", "My Subject", "Line 1\r\nLine 2\r\nLine 3"); If ($email){ echo "E-mail was sent!"; } :-)