Populate answers with hidden fields | Community
Skip to main content
Answered

Populate answers with hidden fields


Hello,

 

I’d like to pre-populate answers to a basic form with a hidden field. Do you know if it’s possible ?

My use-case : i have connected my typeform to Hubspot. I’d like to use answers of my typeform to update Hubspot properties. The form is sent to contacts in my CRM for whom i know the email and can create a hidden field with it. But i need to have a question ‘email’. I’d like to pre-populate the answer with the hidden field in created : ‘email’. Is it possible ?

 

Many thanks !

Best answer by mathio-tf

Hello @virgil 

It is possible to pre-populate answers via a parameter in URL hash.

For example this URL will pre-select 2nd picture in picture choice question:

https://form.typeform.com/to/e5Oy218c#answers-picture=4bc34c11-b8a7-4115-93cb-d13509d2efb0

You can find technical details here:

This approach also works form other fields. If you want to populate just a text field, you can use the value directly in the URL hash. If you want to populate a question like multiple choice, picture choice, etc. (like in the example above) you will need to use option reference as value.

View original

17 replies

Liz
Community Team
Forum|alt.badge.img+5
  • Tech Community Advocate
  • 14840 replies
  • June 25, 2021

Hi @virgil welcome to the community! The Hubspot integration requires that you use the email address field and set it as required. One workaround for this would be to pass the email in through a hidden field and then recall the email into the email field to verify that their email is correct. For example, you could ask, “Is _____ the correct email? If so, please type it below.”

It’s not the best workaround, but hopefully it helps a bit!


john.desborough
Forum|alt.badge.img+6
  • Certified Partner & Champion
  • 5257 replies
  • June 25, 2021

@Liz - this is one of those use cases where the ability to Replace a text variable with the contents of another variable (always assuming it is a text string would be a create start!) would be a wonderful thing.. 

 

I know it is on the list.. but if they are looking for additional use cases.. here’s one. 

 

cheers

 


  • Author
  • Explorer
  • 1 reply
  • June 25, 2021

Thanks for your answer ! In the case of hubspot, one way to get this behavior to work is to create a hidden field with the contact id and add a Zap with Zapier. I’ll try it this way :)

It’s not ideal because it wont use the hubspot integration in typeform.. but it does what i want


mathio-tf
Typeform
Forum|alt.badge.img+5
  • Typeform
  • 888 replies
  • Answer
  • June 28, 2021

Hello @virgil 

It is possible to pre-populate answers via a parameter in URL hash.

For example this URL will pre-select 2nd picture in picture choice question:

https://form.typeform.com/to/e5Oy218c#answers-picture=4bc34c11-b8a7-4115-93cb-d13509d2efb0

You can find technical details here:

This approach also works form other fields. If you want to populate just a text field, you can use the value directly in the URL hash. If you want to populate a question like multiple choice, picture choice, etc. (like in the example above) you will need to use option reference as value.


originalconfidence
Forum|alt.badge.img+1

@virgil I’m curious if your workaround with Zapier is live and working?

I face the same issue and really wondering about it. I mean this is a more than common use case to ask existing customers for a feedback. What a deal and conversion breaker to ask them for the email again when I’ve just send them one. Makes typeform with hubspot pretty useless for us. 
@Liz There is no solution coming up for this in the near future?


Liz
Community Team
Forum|alt.badge.img+5
  • Tech Community Advocate
  • 14840 replies
  • July 29, 2021

@kabir.mathur do you know if we’ll be updating the hubspot integration to accept hidden fields for the email? 


kabir.mathur
Typeform
Forum|alt.badge.img+3

@Liz Yes. We’re planning to add this feature in the upcoming update for this integration.


Liz
Community Team
Forum|alt.badge.img+5
  • Tech Community Advocate
  • 14840 replies
  • July 29, 2021

YAS!!! Glad to hear, @kabir.mathur ! Thank you!!


originalconfidence
Forum|alt.badge.img+1

Thank you for the information!


originalconfidence
Forum|alt.badge.img+1

Hey @kabir.mathur, is there an update on this feature to identify the mailadress by a hidden field from an e-mail send via hubspot?


kabir.mathur
Typeform
Forum|alt.badge.img+3

Hi @originalconfidence. Yes, I’m happy to share that this feature is now available. You can now map hidden fields to Hubspot email fields. 


originalconfidence
Forum|alt.badge.img+1

@kabir.mathur Ok, but how do I now get the hidden field filled in automatically.

My case: I send a typeform with E-Mail integration of the first question via hubspot to my customer. So of course I don’t want to ask for his E-Mail again in the survey. I’ve added the hidden field to the typeform, but don’t get how to fill it with the correct value now.


john.desborough
Forum|alt.badge.img+6
  • Certified Partner & Champion
  • 5257 replies
  • January 28, 2022

@originalconfidence - the link in the email has to have the email parameter added to it like this:

https://yourform.typeform.com/to/ABC123#email=himself@testmail.com

 

where the actual client email is from the hubspot record .. if you have the hidden field created in your receiving typeform, with the same name as the field in the url, then it will capture the email address (in this case) into the hidden field. 

 

hope that helps

 

des


originalconfidence
Forum|alt.badge.img+1

Thanks @john.desborough So far, I don’t get it done. Shouldn’t the URL be like this: https://er028sscj7h.typeform.com/to/HhIfuoAH#email={{email}}

Where is the mistake?


kabir.mathur
Typeform
Forum|alt.badge.img+3

Hi @originalconfidence. Unfortunately, I don’t know much about how Hubspot’s email functionality works. Other email service providers use the concept of merge tags. These tags let you reference values that you already have access to within your account (such as email) and insert those tags into the body of the email to personalize it. 

 

The format of the Typeform URL that you’ve posted in your message seems right to me. It’s probably worth reaching out to Hubspot’s support to see if they can help you out since this issue is related to their functionality. 


originalconfidence
Forum|alt.badge.img+1

Ok, it worked out now finally via hidden field match, BUT what the integration now does is not only updating the existing contact in hubspot. It also creates a new “empty” contact without e-mail, but with the typeform data.

Anyone knows this problem?


  • Navigating the Land
  • 1 reply
  • September 7, 2022
mathio wrote:

Hello @virgil 

It is possible to pre-populate answers via a parameter in URL hash.

For example this URL will pre-select 2nd picture in picture choice question:

https://form.typeform.com/to/e5Oy218c#answers-picture=4bc34c11-b8a7-4115-93cb-d13509d2efb0

You can find technical details here:

This approach also works form other fields. If you want to populate just a text field, you can use the value directly in the URL hash. If you want to populate a question like multiple choice, picture choice, etc. (like in the example above) you will need to use option reference as value.

Does this actually work for other fields asides multiple choice? I’ve tried different ways and it doesn’t work