Skip to main content

I’ve got a form that triggers an outlook email, but I want to put conditions in the html so that the body of the email can change based on the way the form is filled out. For instance, if there are two names added to the form, then the email needs to add “& mname2]” to the greeting, like this:

“Hello, Jake and Kayla!”

If there is only one name in the form, then it would just say:

“Hello, Jake!”

Does anyone know if this is possible?

I’ve tried the html syntax: <%if condition%><%else%><%endif%>

I’ve also tried javascript syntax: <script>if (condition) {} </script>

Neither worked. Here’s where I’m putting it.

 

Hi @jhotchkiss,

Welcome to the Community! 🎉

It looks like what you’re trying to do is not possible since the HTML function in the “Body” field is to only style or format the body of the email. You may want to try adding a Path or Filter for the Zap to only continue on certain conditions.

You can learn more about that here:

Hopefully, this helps!


Reply