Passing custom form data to a hubSpot form in hidden field

Highlighted
New Member

I have made an external javascript Form with multiple steps that pass values from one page through to the next, and so on.

I have made a calculator using javascript form with multiple steps and I want to pass this value in a hidden field in the hubspot form in the last page. The last page is a HubSpot Form, and I am having trouble passing information to that hidden field in the Form.

Can anyone help me to resolve this issue?

Reply
0 Upvotes
3 Replies 3
Community Manager

Hi @Hardeep_Joshi,

Sure thing; what issue are you running into? Are you having trouble getting the value into the field? Can you post a link to the page in question so that I can take a look?

In the meantime, you might find this helpful; if you're changing the value of HubSpot form fields using jQuery, you have to chain the .change() method:

How to customize the form embed code

This is a list of options that you can use if you just need to tweak a default hubspot form. If you need complete control over the styles and actions of your form, you will still want to use the Forms API.

Reply
0 Upvotes
New Member

Hi @ Derek_Gervais,

Yes, I get the value of javascript form field through url in hubspot hidden field. Now, I am stuck confront problem.

The hidden field value in hubspot form is visible when I see it through inspect element(In CONSOLE), but when I click on the submit button on hubspot form the hidden field values are not shown in the contacts and also not in email.

Please help me to resolve this issue.

Thanks,
Hardeep Joshi

Reply
0 Upvotes
Community Manager

Hi @Hardeep_Joshi,

Can you send me a link to the page with that form on it, as well as the corresponding form in your HubSpot portal? It's easiest for me to troubleshoot issues when I can test them out directly. If the page isn't public, feel free to direct message me the details.

Reply
0 Upvotes