我正在尝试使用
我可以在命令行上使用它发送测试电子邮件。
await _expression_
echo "This is the body of the email" | mail -s "This is the subject line" myacc@gmail.com
$transport = new Swift_SendmailTransport('/usr/sbin/sendmail -bs');
$mailer = new Swift_Mailer($transport);
$message = (new Swift_Message('Wonderful Subject'))
->setFrom(['xxx@domain.com' => 'John Doe'])
->setTo(['myacc@gmail.com', 'myacc@xxx.co.za' => 'A
name'])
->setBody('Here is the message itself')
;
我什么也没得到