Open gregality opened 8 years ago
I've hardcoded a multipart/related
string here instead multipart/mixed
in order to test it and it seems it works (at least in Thunderbird and Gmail). OTOH it screw up things a bit in Apple Mail (iOS/iPad): if you're sending some real attachments in the email, not only the CID images, Apple Mail detects that there are attachments but you're not able to download them.
I guess the attachments needs to be sent with the proper Content-Type:
multipart/related
multipart/mixed
My 2 cents.
Hi, I'm currently trying to embed an image in an email using the CID approach. The latest code on the master branch has support for setting the Content-ID, but it doesn't also set the MIME part to "related" (it sets it to "mixed").
In testing, some email clients, notably Gmail and Thunderbird, won't display the images in-line unless the MIME type is set to "related", while other clients (Outlook, Yahoo) will display the images in-line.
Is there a reason why the MIME type is hard-coded to 'mixed'?
See Issue #57 where the MIME spec's are referenced. Also, these stackoverflow posts are helpful:
http://stackoverflow.com/questions/3902455/smtp-multipart-alternative-vs-multipart-mixed
http://stackoverflow.com/questions/19497672/multipart-messages-including-multiple-attachments-attachment-and-inline-wi
Thanks!