[L9] Why are embedded images being turned into attachments? #46585
Unanswered
jcmcclorey
asked this question in
Q&A
Replies: 1 comment 3 replies
-
I have the same problem. Did you ever figure out a solution? |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Laravel: v9.52.4
PHP: v8.0.28
I recently upgraded from v7 to v9 and now I'm noticing that embedded images in my emails are being treated as regular attachments in most email clients and not actually rendering where they should be. I have tested in Outlook, Gmail and ProtonMail and Outlook is the only one that renders the images correctly, even so, it shows the attachment icon (paperclip) in the UI as if there is an attachment.
Here's how I'm embedding these images which as far as I can tell matches up with the docs.
I came across this article which seems to imply that I would want the Content-Type to be set to "multipart/related" in the header. I was able to check the header key-value pairs for emails sent to Outlook and the older, L7 emails have Content-Type set to "multipart/related", but in the newer L9 emails it's set to "multipart/mixed". So I believe that supports my conclusion that I need to use "multipart/related".
In L7 I was using the old
build()
Mailable
method to build my emails and I have tried using the newheaders()
,envelope()
andcontent()
Mailable
methods, but there aren't any changes to the header key-value pairs which I have tried setting.For example:
Beta Was this translation helpful? Give feedback.
All reactions