- xml - AJAX/Jquery XML 解析
- 具有多重继承的 XML 模式
- .net - 枚举序列化 Json 与 XML
- XML 简单类型、简单内容、复杂类型、复杂内容
我正在使用 golang 通过以下方法通过 exim 发送电子邮件
const sendmail = "/usr/sbin/exim"
func submitMail(m *gomail.Message) (err error) {
cmd := exec.Command(sendmail, "-t")
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr
pw, err := cmd.StdinPipe()
if err != nil {
return
}
err = cmd.Start()
if err != nil {
return
}
var errs [3]error
_, errs[0] = m.WriteTo(pw)
errs[1] = pw.Close()
errs[2] = cmd.Wait()
for _, err = range errs {
if err != nil {
return
}
}
return
}
问题是 Exim 使用 -t
删除了 BccIf Exim is called with the -t option, to take recipient addresses from a message's headers, it removes any Bcc: header that may exist (after extracting its addresses), unless the message has no To: or Cc: header, in which case a Bcc: header with no addresses is left in the message, in accordance with RFC 822. If -t is not present on the command line, any existing Bcc: header is not removed.
If Exim is called to receive a message with the recipient addresses given on the command line, and there is no Bcc:, To:, or Cc: header in the message, it normally adds a To: header, listing the recipients. Some mailing list software is known to submit messages in this way, and in this case the creation of a To: header is not what is wanted. If the always_bcc option is set, Exim adds an empty Bcc: header instead in this circumstance.
最佳答案
-t
的“Sendmail look alike”模式删除 Bcc:
header 处理后。
在 -t
模式下 Bcc:
header 内容将附加到 (SMTP) 收件人列表中 BUT 收件人将看不到/接收 Bcc :
header 。
风格指南建议:如果您在“sendmail look alike”(命令行比较模式)中使用另一个 SMTP/MTA 软件(例如 Exim)那么 使用他们提供的 sendmail 程序/二进制文件。const sendmail = "/usr/sbin/sendmail"
关于go - 如何通过 `exim -t` 发送密件抄送电子邮件? ["sendmail look alike"模式],我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49962086/
我在理解以下行为时遇到了一些麻烦 方案方案: (define c (dynamic-wind (lambda () (display 'IN)(newline)) (lambda
我多次尝试去理解 continuations 的概念和 call/cc 。每一次尝试都失败了。有人可以向我解释一下这些概念吗?最好用比维基百科或其他帖子中的例子更现实的例子。 我有网络编程和面向对象编
所以我正试图在 Scheme 中找出整个 call/cc 的东西。下面是我正在使用的代码: (+ 1 (call/cc (lambda (k) (if (number? k)
所以我正试图在 Scheme 中找出整个 call/cc 的东西。下面是我正在使用的代码: (+ 1 (call/cc (lambda (k) (if (number? k)
当我将我的应用程序从 Solaris C 编译器 sunstudio/v12/SUNWspro 迁移到 Linux C 编译器 GCC 版本 4.1.2 20080704 时,我看到了 CC 无法识别
这个程序正在运行,但是如何发送多个CC和BCC。 for($i = 0; $i \r\n"; $headers .= "Reply-To: \r\n"; $hedders .= "c
我的 makefile 中有以下内容: CC = cc -g -KPIC 当我运行 makefile 时,出现以下错误。 cc -g -KPIC -DORA817 -DIDA_VERSION='"
我有一个测试脚本,它在内部调用 make 来编译示例 C 程序。但由于某些未知的原因,编译没有进行。它抛出以下错误: 08-27 20:23:45.777 make program c
谁能帮助我使用 Java 代码打开带有收件人、抄送、主题和正文的 Outlook 邮件客户端。尝试使用以下代码 import java.awt.Desktop; import java.net.URI
尝试使用此命令安装 perl 的 Encode::Detect 模块时出现以下错误 perl -MCPAN -e "install Encode::Detect" 错误信息 cc: error try
在旧版 Office API 的文档中,我发现可以在用户撰写电子邮件时监视“收件人/抄送”字段的更改。这是否在 Office 365 的新 Javascript API 中公开?我似乎无法找到明确的答
我是一名优秀的程序员,十分优秀!