Many of the code elements in the e-mail template (the JHTML or JSP file that contains the body of the message) refer to visitor profiles in your profile repository. For example, the JSP code <dsp:valueof bean="Profile.firstName"/> refers to the firstName property of the visitor profile – in other words, to the first name that you have stored for each visitor. For each person to whom you send the message, the ATG system checks the current value in that property (in this case, “Michelle”) and inserts that value into the appropriate place in the text of the message. It performs this process for every code element in the file.

As another example, the code <dsp:valueof param="element.name/"> refers to a set of catalog products that your application developer has included in a targeting servlet bean called crossellTargeter. When it produces the message, the system checks the targeting servlet bean and inserts the element.name values specified by the bean (in this case, “Arribia bike shorts,” “Springtrak insulated water bottle,” and “Springtrak shatterproof helmet”) into the appropriate place in the text of the message.

In this way, the system builds an e-mail message that is different for every recipient.

Note that the example shown above uses setvalue parameters for the “Subject” and “From” fields in the e-mail. Using this feature means that even these fields can change according to the recipient. You could change the Subject field so that, instead of just stating “Order Confirmation,” it includes the name of the product that each recipient has ordered, for example “Order Confirmation: Arribia Cycling Gloves.” In addition, by changing the subject line, you could use one template file for different purposes, saving development time. This feature makes the e-mail template highly flexible.

For information on different methods for defining the “Subject” and “From” fields, please refer to the targeted e-mail chapter in the ATG Personalization Programming Guide.

 
loading table of contents...