symfony-docs
symfony-docs copied to clipboard
How to set encoder(8bit,base64 or quoted-printable) in symfony mailer
Can you please elaborate a bit more what piece of information you are missing?
@xabbuh there is an option in php mailer for setting content transfer encoding to one of these methods 8bit,base64, 7bit & quoted-printable. Also there is way to set encoding method in swiftmailer but in symfony I did not see any documentation to set one of the value from above methods
I think we need an easy way to configure that in the code itself first (see symfony/symfony#44557).
In SwiftMailer
5.x
we had setEncoder
+ get8BitEncoding
etc. so you could do
$message->setEncoder(\Swift_Encoding::get8BitEncoding());
However, this was removed in 6.x
: https://github.com/swiftmailer/swiftmailer/commit/d210d674809310dac02da09b372bf74a8047c2ab
I'm wondering why this was removed? :thinking: I can't find a good solution to encode emails other than quoted-printable. Anyone?
I'm closing this one because the related code issue was closed after "expiring" (https://github.com/symfony/symfony/issues/44557).
Please, try to ask about this in the GitHub Discussions or Slack chat shown in https://symfony.com/support If there's enough interest, the next step would be to create an issue in the code repository and try to gather some support for it. Finally, there could be a PR in the code repository and then we would document it here.
Thanks for understanding.
No need to create a new issue. The last comment in the original issue states:
Feel free to comment if this is still relevant, I can always reopen!