PHPmailer向用户群发送大量邮件-我应该使用密件抄送还是单独的电子邮件? [英] PHPmailer sending bulk to a user base - should I use BCC or individual emails?

查看:133
本文介绍了PHPmailer向用户群发送大量邮件-我应该使用密件抄送还是单独的电子邮件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个拥有数百名用户的用户数据库,这些用户需要接收通过每周计划任务发送的每周更新电子邮件.

使用PHPmailer时,最好是在密件抄送"字段中向所有用户发送一封电子邮件,还是使用标准的AddAddress字段发送多封电子邮件?

在服务器上哪个更容易和/或哪种方法比另一种更有效率?

解决方案

个人电子邮件.密件抄送在服务器上更容易,但是却给您带来很少的控制权,并且有更大的空间将错误的信息发送给许多人.

从服务器配置的角度来看,SMTP到localhost是提交邮件最快(也是最安全)的方式.

要有效地发送单个消息,请参阅随邮件一起提供的示例PHPMailer ,并阅读有关发送至列表的Wiki文章.最重要的事情是将PHPMailer实例重用于多条消息,循环清除收件人,并使用keepalive.

I have a user database with a few hundred users who need to receive a weekly update email, sent via a weekly scheduled task.

When using PHPmailer, would it be better to send one email with all users in the BCC field, or multiple emails using the standard AddAddress field?

Which is easier on the server and/or is one way more efficient than the other?

解决方案

Individual emails. BCC is easier on the server, but gives you very little control, and there's more scope for sending the wrong thing to many people.

From a server config point of view, SMTP to localhost is the fastest (and safest) way of submitting messages.

To send individual messages efficiently, see the mailing list example provided with PHPMailer, and read the wiki article on sending to lists. The most important things are reusing the PHPMailer instance for multiple messages, clearing recipients in a loop, and using keepalive.

这篇关于PHPmailer向用户群发送大量邮件-我应该使用密件抄送还是单独的电子邮件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆