I have a B4J server program that must send automated Mails, with a picture and other data. The picture won't be stored in the server, so it is sent as an attachment.
I can successfully build these mails with a quite simple HTML formatting and add the picture attachment. They are correctly received con the client side.
However, if I want to embed the same picture in the HTML mail body, so that it can be seen as part of it in the relevant section, I see that some mail clients (Outlook) display them correctly, while others (GMail) simply don't.
Seems that this behavior depends on the mail client itself, but also that there is more than one option to compose them: I have tried
- as a cid reference --> correctly displayed in outlook, but not in GMail
$"<img width="400" height="640" src="cid:${p.Get("pictureName")}">"$
- using base-64 --> not displayed in Outlook nor GMail (perhaps I'm doing something wrong)
Does anyone know of any 'composing' option so that the image correctly shown in the message body (at least with most mail clients) or is it something one must live with?