I have created a VisualForce template. I need to use its advanced wiring facilities so can't use other template types.

I am trying to have some HTML in this template but not having much luck.

I add:

<I>This should be in italic</I>

to the template but it comes out verbatim as:

<I>This should be in italic</I>

Any ideas how I can add HTML to a visual force template?

  • Have you pasted it to <messaging:htmlEmailBody > or <messaging:plainTextEmailBody>? – eyescream Nov 21 '12 at 9:48
  • You just beat me to it. Yes that works. If you want to put that in as an answer, I'll accept it and delete my own. – dublintech Nov 21 '12 at 9:57
  • 1
    That's fine, accept your own answer ;) I'm not THAT greedy for the rep. points and after all it means you did your own research. – eyescream Nov 21 '12 at 10:06
<messaging:emailTemplate subject="Sample Disbursement Receipt" recipientType="User"  relatedToType="Call__c">
 <messaging:htmlEmailBody >
Please find your sample drop receipt attached with this mail.

The sample Template that you can use .

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.