PHP Mail $从数据库表发送给多个收件人
<?php include("admin/db.php");
$recipients = "SELECT * FROM recipients ORDER BY id DESC";
$email_list = $db->query($recipients);
foreach($email_list as $row) {
echo $row['email'].",";
}
$to = "?";
?>
上面我有一个以逗号分隔的电子邮件列表,我需要将其插入到 $to 变量中。我该怎么做?
<?php include("admin/db.php");
$recipients = "SELECT * FROM recipients ORDER BY id DESC";
$email_list = $db->query($recipients);
foreach($email_list as $row) {
echo $row['email'].",";
}
$to = "?";
?>
Above I have a comma delimitated list of emails which I need to insert into the $to variable. How do I do this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)