function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
dcarmen66dcarmen66 

How to include a document image in a Visualforce Email Template

I was trying to embed a Document as an image as a Letterhead for a Visualforce Email template, since it says you can't use static resources for this. There wasn't a lot of documentation around it, but I did come across something that says to use something like this:

<apex:image id="Logo" value="https://na12.salesforce.com/servlet/servlet.ImageServer?
id=015U00000006rgj&oid=00DU0000000IaH2&lastMod=127057656800"  />

 

When I put that the VF template, the spot where the image should go displays, but the image does not.

Is this the correct way to be doing this? What value should be in the "lastMod" parameter. I don't see anything that described what that should be. I did put the correct values for the id and oid, and for the salesforce instance, but can't find anything for "lastMod".

 

Thanks in advance!

vriavmvriavm

Is the document made externally available?

dcarmen66dcarmen66
Yes the document is externally available. It doesn't even show on the preview though. --Sent from my mobile phone--
ManojjenaManojjena
Please use "src" attribute in place of value.