【问题标题】:hmailserver 550 invalid address error sending via php formhmailserver 550 无效地址错误通过 php 表单发送
【发布时间】:2012-09-19 21:52:18
【问题描述】:

我已经 2 天没完没了地收到此错误。尽管遵循所有正确的协议调用。该错误表明电子邮件无效,但我将它与松鼠邮件一起使用没有问题,并且在 php.ini 中看起来完全相同但是我可以弄清楚当我回显 $header 它显示“发件人:admin@daysshared.local”是正确的,它是否认为发件人是电子邮件地址的一部分。我正处于一起放弃的风口浪尖,所以如果可以的话,请帮助我。谢谢。继承人的PHP:

$subject = "Your New Password";
$headers = "FROM: admin@dayshare.local";
$message = "Your new password is as follows:

----------------------------
Password:$emailpassword
----------------------------

This email was automatically generated.";

      if (!mail($email,$subject,$message,$headers)){
         echo ("error");
      }else{
            echo"password sent";

在 php.ini 中:

SMTP = localhost
smtp_port = 25
sendmail_from = admin@dayshare.local

【问题讨论】:

    标签: php smtp


    【解决方案1】:

    我知道这是旧的,但只是偶然发现它。你现在可能已经修复了它...... 你提到

    显示“发件人:admin@daysshared.local”

    但你的标题是

    $headers = "FROM: admin@dayshare.local";

    dayshared.local 和 dayshare.local 不同

    【讨论】:

      猜你喜欢
      • 2023-03-16
      • 2013-03-27
      • 2012-02-05
      • 1970-01-01
      • 2015-02-22
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多