作者热门文章
- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我有一个填写要发送给我们客户的PHP邮件的表格,由于隐私原因,我想对大多数客户进行密送。我有以下代码
$to = "******@e-track.co.za"; //To recipients
$email_from = '*****@etrackbureau.co.za';//<== update the email address
$email_subject = "New Overdue Loaded";
$email_body = "A new High Risk Client has been loaded by $name $company.\n".
"\n Client Name: $driver_name $driver_surname\n
\n Client ID or Passport Number: $driver_id\n
\n Nationality: $driver_nationality\n
\n Reason for Loading Client: $type\n
\n Notes: $notes\n
".
$headers = "From: $email_from \r\n";
$headers = "Bcc: ******@e-track.co.za;*****@e-track.co.za;******@e-track.co.za\r\n";
//$headers = "Reply-To: $visitor_email \r\n";
//Send the email!
mail($to,$email_subject,$email_body,$headers);
最佳答案
您应该连接$headers
范例:
$headers = "From: *****@etrackbureau.co.za\r\nX-Mailer: php\r\n";
$headers .= "MIME-Version: 1.0\r\n"; #Define MIME Version
$headers .= "Content-Type: text/html; charset=ISO-8859-1\r\n"; #Set content type
$headers .= "Bcc: $EmailListHere\r\n"; #Your BCC Mail List
关于php - PHP邮件添加密件抄送,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43181025/
我是一名优秀的程序员,十分优秀!