Page 1 of 1
mil() sending as unknown sender?
Posted: Thu Jul 22, 2004 6:32 pm
by pinehead18
mail($email, "s.com - You have a new message", "You have a new mail message waiting for you in your
mail box. Click here to go to your inbox:
http://www.", "FROM:
yoda@gmail.com");
When this arrives in $email's in box (anybody) it is from "unknown sender"
any ideas it is from an unknown sender rather than
yoda@gmail.com?
Posted: Thu Jul 22, 2004 6:47 pm
by feyd
You may need Reply-To and Return-Path, there may be others.. Maybe naming your email address like "From: pinhead18 <
yoda@gmail.com\r\n"..
Posted: Thu Jul 22, 2004 6:48 pm
by pinehead18
That doesn't make much since to me, you don't know of any tutorials on it do ya?
Posted: Thu Jul 22, 2004 6:51 pm
by feyd
nothing more than the php.net man page for it:
mail
Posted: Thu Jul 22, 2004 6:55 pm
by pickle
According to the manual, the from field has to be lowercase, and ended by \r\n. Take a look: [php_man]mail[/php_man]
Posted: Thu Jul 22, 2004 6:58 pm
by pinehead18
well see the crappy thign is that did not fix it and the
yoda@gmail.com appears at the top of the email but not in the from spot.
Any other ideaS?
Posted: Mon Jul 26, 2004 1:59 am
by zeroanarchy
Hi pinehead18,
I have the exactly same problem and after reading around 20posts I have not come up with an answer. I keep getting the From line coming up as From: Nobody. the from line comes up in the message rather than where it should be in the From line.
I have tried
Code: Select all
mail ($to, $subject, $message, "$from\r\nX-Priority: 1 (Highest)")
or Print "Counld not send mail";
Code: Select all
mail ($to, $subject, $message, $from) or Print "Counld not send mail";
Code: Select all
mail ("$recipient","$subject","$body", "From: Your Name<youremail@yourdomain.com>\r\nReply-To: youremail@yourdomain.com\r\n");
I am under the impression it is an error with a setting in the server, can anyone clarify this or perhaps offer a solution?
Cheers
zero
Posted: Mon Jul 26, 2004 3:28 am
by zeroanarchy
ok just thought this might help anyone who comes up with the same problem here is what ended up working:
Cheers
zeroanarchy
Code: Select all
$to ="who@here.com";
$from = "$username <$emailfrom>";
$subject = "the subject";
$message = "$usermessage";
mail ("$to","$subject","$message","from:$from\n") or Print "Could not send mail";
?>