1
我使用PHPGmailer爲註冊用戶發送了一些重要通知。該電子郵件是Google應用程序供電。如何向用戶發送通知郵件,避免被phpgmailer標記爲垃圾郵件?
這裏與PHPGMailer類我對發送的電子郵件功能配置:
function send_mail($to, $subject, $content)
{
$mail = new PHPGMailer();
$mail->Username = '[email protected]';
$mail->Password = 'xxxxxx';
$mail->From = '[email protected]';
$mail->FromName = 'domain';
$mail->Subject = $subject;
$mail->CharSet = 'UTF-8';
$mail->AddAddress($to);
$mail->IsHTML(true);
$mail->Body = $content;
$mail->Send();
}
是它發送的通知不夠好,防止被標記爲垃圾郵件?或者添加更多的額外配置和設置?
你沒有說你是否通過Google MTA路由電子郵件,無論MX指向Google的服務器還是該域的SPF。 – symcbean
@symcbean什麼是Google MTA?爲了創建Google App的Gmail帳戶,必須先從域設置中更改MX記錄。這足夠嗎? – Angolao