Newer Version Available

This content describes an older version of this product. View Latest

messaging:emailHeader

Adds a custom header to the email. The body of a header is limited to 1000 characters.

Example

1<messaging:emailTemplate recipientType="Contact"
2	relatedToType="Account"
3	subject="Testing a custom header"
4	replyTo="support@acme.com">
5            
6	<messaging:emailHeader name="customHeader">
7		BEGIN CUSTOM HEADER
8		Account Id: {!relatedTo.Id}
9		END CUSTOM HEADER
10	</messaging:emailHeader>
11            
12	<messaging:htmlEmailBody >
13	<html>
14	<body>
15            
16	<p>Dear {!recipient.name},</p>
17   	<p>Check out the header of this email!</p>
18	</body>
19	</html>
20	</messaging:htmlEmailBody>
21</messaging:emailTemplate>

The example above renders the following HTML:

1Date: Thu, 5 Feb 2009 19:35:59 +0000
2From: Admin User <support@salesforce.com>
3Sender: <no-reply@salesforce.com>
4Reply-To: support@acme.com
5To: "admin@salesforce.com" <admin@salesforce.com>
6Message-ID: <19677436.41233862559806.JavaMail.admin@admin-WS>
7Subject: Testing a custom header
8MIME-Version: 1.0
9Content-Type: multipart/alternative;
10boundary="----=_Part_8_14667134.1233862559806"
11X-SFDC-X-customHeader: BEGIN CUSTOM HEADER Account Id: 001x000xxx3BIdoAAG END CUSTOM HEADER
12X-SFDC-LK: 00Dx000000099jh
13X-SFDC-User: 005x0000000upVu
14X-Sender: postmaster@salesforce.com
15X-mail_abuse_inquiries: http://www.salesforce.com/company/abuse.jsp
16X-SFDC-Binding: 1WrIRBV94myi25uB
17X-OriginalArrivalTime: 05 Feb 2009 19:35:59.0747 (UTC) FILETIME=[F8FF7530:01C987C8]
18X-MS-Exchange-Organization-SCL: 0

Attributes

Attribute Name Attribute Type Description Required? API Version Access
id String An identifier that allows the emailHeader component to be referenced by other components in the page. 14.0 global
name String The name of the header. Note: X-SFDC-X- is prepended to the name. Yes 14.0
rendered Boolean A Boolean value that specifies whether the component is rendered on the page. If not specified, this value defaults to true. 14.0 global