Add customer property in Form Redirect to an external site


We have a form that redirects to an external site. I would like to append the form redirect link with a custom customer property. I tried to add this external link:{{contact.affiliateid}}

Unfortunately it doesn’t append the affiliateid to the url when it redirects. Is there a way to do this?

If so, is there a way to make it conditional so that ?affiliateid= only appears if the user has that field. I can create a button by using the code below but I’d like it to work from the form.

Button Code:

{% if contact.affiliateid %}
<p><a class="hs-button primary" href="{{contact.affiliateid}}" target="_blank">Order Now</a></p>
{% else %}
<p><a class="hs-button primary" href="" target="_blank">Order Now</a></p>
{% endif %}


Hi @revealio

Can you tell me more about how you’d be using that property on the redirect page? Our forms don’t currently have any options to dynamically append data to the redirect URL.


I have to use the property in the URL. I think we may have found a solutions over in the Community forum:


Would the affiliateId be set before the contact gets to the page? That solution would work but only if the property is set before the form is loaded onto the page, it wouldn’t add the parameter to the redirect if they’re putting that information into the form.