How to use images in Email templates in salesforce
If u place images in static resource and access them in email templates sometimes images would not display.So it is recommended to follow the below procedure.
Step 1:
Upload the image to document.
Step 2:
On the image right click-->copy image location
Step 3:
replace src with the copied url.
For example the url will be like this
In visualforce email template
<apex:image id="imageid" value="https://na7.salesforce.com/servlet/servlet.ImageServer?id=015D000000Dpwc&oid=00DD0000000FHaG &lastMod=127057656800 height="70" width="80"/>
In custom email template
<img id="imageid" src ="https://na7.salesforce.com/servlet/servlet.ImageServer?id=015D000000Dpwc&oid=00DD0000000FHaG &lastMod=127057656800 height="70" width="80"/>
If u place images in static resource and access them in email templates sometimes images would not display.So it is recommended to follow the below procedure.
Step 1:
Upload the image to document.
Step 2:
On the image right click-->copy image location
Step 3:
replace src with the copied url.
For example the url will be like this
In visualforce email template
<apex:image id="imageid" value="https://na7.salesforce.com/servlet/servlet.ImageServer?id=015D000000Dpwc&oid=00DD0000000FHaG &lastMod=127057656800 height="70" width="80"/>
In custom email template
<img id="imageid" src ="https://na7.salesforce.com/servlet/servlet.ImageServer?id=015D000000Dpwc&oid=00DD0000000FHaG &lastMod=127057656800 height="70" width="80"/>
No comments:
Post a Comment