【发布时间】:2014-03-01 03:34:30
【问题描述】:
我有一个 ruby 应用程序,我正在使用文档http://ruby-doc.org/stdlib-2.0/libdoc/net/smtp/rdoc/Net/SMTP.html 中的这种格式发送电子邮件:
这是一个示例代码:
def send_notification(exception)
msgstr = <<-END_OF_MESSAGE
From: Exchange Errors <exchangeerrors@5112.mysite.com>
To: Edmund Mai <emai@mysite.com>
Subject: test message
Date: Sat, 23 Jun 2001 16:26:43 +0900
Message-Id: <unique.message.id.string@mysite.com>
This is a test message.
END_OF_MESSAGE
Net::SMTP.start('your.smtp.server', 25) do |smtp|
smtp.send_message msgstr, 'from@address', 'to@address'
end
end
如何为这封电子邮件强制使用字体?我想强行给Courier New。
【问题讨论】: