0

I'm creating an email template using Kentico's email marketing module. In which I have an email widget that retrieves and fills in holiday detail parameters based on some custom contact field values therefore making this dynamic for each user.

How can I pass custom contact fields in to the widgets from the recipient? The recipient object only contains set values.

Contacts for this email campaign are collected from a form submission that passes in the required values.

<div style="display:none;">
    {% holidayDate = Recipient.GetValue("holidayDate"); #%}
    {% holidayId = Recipient.GetValue("holidayId"); %}
    {% ItineraryData = customNamespace.GetItineraryItem(holidayId, holidayDate) #%}
</div>

<h2 class="price">{% ItineraryData.GetValue("Price") #%}</div>

Something like the above is what I am trying to achieve but I can't seem to work out how to get these custom fields to use in the email widget.

Thanks, Luke

1 Answer 1

1

The documentation states Recipient only has 4 available fields:

  • FirstName
  • LastName
  • Email
  • PersonaID

If you want to get custom fields, you'll have to look up the contact by the email address, first and last name in a macro.

1
  • Thanks for this Brenden. Is it possible to get the field value out of a bizForm this way using a macro. Looking up using the same parameters you mentioned? FirstName, LastName and Email? Do you know of an example of how to achieve this?
    – Hooky17
    Jun 12, 2018 at 12:52

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.