Reply template - best way to show inline images
Hey,
The 100 000 dollar question.
Whats the best way to try and prevent blocking of images sent from an reply template through the Email class.
Most customers accepts that images are blocked by default and its simply a standard on the web..
But, we have one customer that really dont accept this, so, i figure i´ll ask here anyway if anyone have a solution.
We get the same result using uploaded attachment images as well as using a base64.
It seems that it might work with using CID, but, not sure how to fix this throu reply templates.
Any ideas?
Regards
Pär
I
Alle Antworten (3)
Hi Par,
If you add the images as an attachment when populating the Email class, this should work reliably:
email.addAttachment(1841313, true);
(where 1841313 is the attachment ID in SO).
You can combine this logic in a reply template by adding the image as shown below:
< img alt="Example" src="cid:att-0@online.superoffice.com" style="width: 71px; height: 71px;" >