duanpao9781
2012-11-26 00:31
浏览 46
已采纳

在SwiftMailer生成的电子邮件中更改Multipart Boundary?

Thanks for reading!

I want to change the default multipart boundary string in a message generated by SwiftMailer.

SwiftMailer seems to automatically generate the string, and includes the string "swift_v4...", like so:

--_=_swift_v4_135388916050b2b5889e516_=_

        ...Text Message Part...

--_=_swift_v4_135388916050b2b5889e516_=_

        ...HTML Message Part...

--_=_swift_v4_135388916050b2b5889e516_=_

I don't see anything in the documentation, but before I go digging around in the code, does anyone know a way to change this via the SwiftMailer interface?

图片转代码服务由CSDN问答提供 功能建议

感谢阅读!

我想更改默认值 SwiftMailer生成的消息中的多部分边界字符串

SwiftMailer似乎自动生成字符串,并包含字符串“swift_v4 ...”,如下所示:

  --_ = _ swift_v4_135388916050b2b5889e516 _ = _ 
 
 ...文本消息部分... 
 
 --_ = _ swift_v4_135388916050b2b5889e516 _ = _ 
 
 ... HTML 消息部分... 
 
 --_ = _ swift_v4_135388916050b2b5889e516 _ = _ 
   
 
 

我没有在文档中看到任何内容,但在我开始挖掘之前 代码,有没有人知道通过SwiftMailer接口改变它的方法?

  • 写回答
  • 好问题 提建议
  • 关注问题
  • 收藏
  • 邀请回答

2条回答 默认 最新

  • dtntjwkl83750 2012-11-26 04:40
    已采纳

    Judging from the source code, this can be done simply via Swift_Message::setBoundary().

    已采纳该答案
    评论
    解决 无用
    打赏 举报
  • duan6161 2012-12-08 05:28
      $message = Swift_Message::newInstance()           # Create the message
    ->setBoundary('Your boundary')
    # more code
    
    评论
    解决 无用
    打赏 举报

相关推荐 更多相似问题