Add customer property in Form Redirect to an external site


#1

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: http://order.revealio.com/revealio-book-covers-payment?affiliateid={{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="http://www.order.revealio.com?affiliateid={{contact.affiliateid}}" target="_blank">Order Now</a></p>
{% else %}
<p><a class="hs-button primary" href="http://www.order.revealio.com" target="_blank">Order Now</a></p>
{% endif %}

#2

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.


#3

I have to use the property in the URL. I think we may have found a solutions over in the Community forum: https://community.hubspot.com/t5/COS-Design-Support/Add-customer-property-in-Form-Redirect-to-an-external-site/m-p/4514/highlight/false#M431


#4

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.