【发布时间】:2014-09-16 09:47:25
【问题描述】:
我会让它变得非常简单。我想通过php发送电子邮件。现在这里是代码。
$line = '\n';
$a = "Customer Phone: ";
$b = "Customer Last Name: ";
$message = $a.$number.$line.$b.$LastName;
$to = "forgotten_tarek@yahoo.com";
$subject = "Umrah Booking";
$from = $mailer;
$headers = "From:" . $from;
mail($to,$subject,$message,$headers);
这是输出:
Customer Phone: 0712345678\nCustomer Last Name: Showkot
并且电子邮件显示没有发件人。上面写着nobody。
我希望电子邮件看起来像:
Customer Phone: 0712345678
Customer Last Name: Showkot
我还想表明该电子邮件来自example@example.com
【问题讨论】: