How to show the static resource image in visualforce email template - Salesforce Globe For You
Solution: Use <apex:image url="{!$Resource.staticresourcename}" width="50" height="50"/> to display image
Example:
<messaging:emailTemplate subject="Visualforce Email Template Demo" recipientType="User" relatedToType="Account">
<messaging:htmlEmailBody >
<html>
<body>
<div>
<apex:image url="{!$Resource.TestLogo}" width="50" height="50"/>
</div>
</body>
</html>
</messaging:htmlEmailBody>
</messaging:emailTemplate>
Output:
No comments:
Post a Comment