【问题标题】:Using CFMAIL tag to send emails with an image使用 CFMAIL 标签发送带有图像的电子邮件
【发布时间】:2011-09-14 05:25:47
【问题描述】:

我的代码如下,

<cfmail
    to="sender@xyz.com"
    from="receiver@xyz.com"
    subject="email with image">

    <img src="cid:pClip" width="350" height="85" alt="" />

    there is an image above this msg.

    <cfmailparam file="#ExpandPath('PaperClip.jpg')#"
        contentid="pClip"
        disposition="inline" />

  </cfmail>

我得到了这个工作,但现在的问题是图像显示为附件,不是内联(邮件客户端:Outlook 2010)。有什么建议吗?

【问题讨论】:

  • 我的代码中已经有以下解决方案 (type="html"),但是您的 IMG 嵌入代码帮助我解决了 Outlook 中的附件问题。你的问题解决了我的问题。谢谢!

标签: coldfusion coldfusion-8 cfmail


【解决方案1】:

你需要给你的 cfmail 标签添加一个 type 属性

<cfmail
    to="sender@xyz.com"
    from="receiver@xyz.com"
    subject="email with image"
    type="html">

【讨论】:

  • 是的,这就是缺少的。谢谢。
猜你喜欢
  • 2012-10-02
  • 1970-01-01
  • 2013-06-01
  • 1970-01-01
  • 2020-06-12
  • 1970-01-01
  • 2018-04-27
  • 2017-04-22
  • 1970-01-01
相关资源
最近更新 更多