Can I insert a Field into an Email, with a Fallback option?

Dear %FirstName%

But if there is no value for FIRSTNAME then set it to something else, maybe “friend”

Or even better:

If %FirstName% THEN “Hi %FirstName%,” ELSE “”

so they get either:

Hi Bob,
or
nothing

1 Like

Found answer on Forum:

%IF $FIRSTNAME != ‘’%
Hi %FIRSTNAME%,
%ELSE%
Hi,
%/IF%

1 Like

Hi @bungalowsoftware,

If you go to the “Forms” page and then click in the top left “Manage Fields” you can add/edit a different value or default value if there is no, for example, %FIRSTNAME% associated with the contact.

You would get there by clicking “Edit” in the specific field name row. You will then be given the option to add a “Default value”. See image below for an example.

Let me know if you need any more help, thanks,

Perry

1 Like

I haven’t yet tested the solution @bungalowsoftware posted above but it looks neat and I wonder why it’s not shown in the docs as an alternative to setting a default value. Having only one default values for a firstname for example is a bit unhandy as you Probably want to change it on every campaign depending on the context.

Good to know there’s the if/else way in the template. I’m gonna try that out.

Hello team! Just wanted to add more insights regarding adding default values to your emails.
Personalization tags are definitely a great way to keep your campaigns personalized, but there are sometimes where there is room for a default value in case your contacts don’t have that field within their profile. So instead of having a blank space, you can create this default value following these steps:

  1. Click Contacts.
  2. Click Fields.
  3. Locate the field you wish to add a default value to and click the pencil icon
  4. Type the default value into the field provided and click “Save.”
  5. For more insights, you can check our detailed article: HERE.

Hope this helps, and remember you can always contact us in case anything comes up along the way!