Thursday, June 12, 2003 09:05 AM
I think you have to use multipart/related overall, e.g. so the main body part can refer to/link to the image (attachment) part, if you expect to display the image inline in the body. And you have to set the content-type of the part containing the image content, to the appropriate string e.g. "image/gif", "image/jpeg", etc... And of course a message containing any binary data is supposed to be encoded for transit e.g. Content-Transfer-Encoding:base64, to protect it in transit, since only 7-bit ascii is guaranteed to make it unmolested through SMTP. But then it gets decoded by the mail client application that receives it.