Ability to redirect to multiple thank you page based on form response
On a form, there is a field with two different responses, which helps to determine the ideal customer. It is very important to have the feature to redirect a visitor to separate thank you pages based on the response. To B2B customers, we sell our products directly but to B2C customers, we redirect them to e-commerce channels (such as eBay or Amazon). In this case, both the types of customers are important. We can use one landing page and form to target both types of audiences to promote the product but redirect them to the relevant offer/content based on the response.
I’m Ian, the Product Manager for HubSpot’s Forms tool.
Thanks to all of you tha have expressed interest in participating in user testing. You're welcome to continue expressing your interest here. I'll reach out to you directly when we have opportunities to participate.
Any news about this feature request will be relayed on this thread, so stay tuned!
I’m Ian, the Product Manager for HubSpot’s Forms tool.
Thank you all for taking the time to submit, upvote, and comment on this Idea. We hear you loud and clear, and we agree that this functionality is important. We are currently evaluating how our team will implement this idea. If you're interested in participating in user testing, just reply to this thread.
Any news about this feature request will be relayed on this thread, so stay tuned!
I have a form with a field that asks a question with two different responses. It would be good to have the functionality to redirect to separate thank you pages based on the response.
For example, if Mr Lead chooses answer A, they will go to thank you page A, if they choose answer B, they will go to thank you page B.
This would allows us to present our leads with content that truly is relevant to them.
This would be an absolute blessing for us to redirect our demo users in a relevant direction instead of a generic Thank you page and then emailing information. This would cause less friction for the visitors, making it an effortless experience.
Hi there, I've been following this thread with great interest and attempting to implement this on a HS landing page. I can't seem to get this working however so hoping someone could shed some light?
I'm using multi-dropdown select box in my form, so I've been trying to adjust the embed code from @anders_grove but I'm not 100% certain on how to do this.
I'm using a HTML module in the landing page to embed the modified code, is that correct? It's just not appearing at all on my page so I'm obviously going wrong somewhere.
Then I'm trying to adjust the code as follows but again, not 100% sure if I've got it right - any help would be greatly appreciated:
<!--[if lte IE 8]>
<script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/v2-legacy.js"></script>
<![endif]-->
<script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/v2.js"></script>
<script>
hbspt.forms.create({
portalId: "xxxxxx",
formId: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
css: "",
onFormSubmit: function($form) {
var choice = $('select[name="catagory"]').val(); << Is this the name of the contact property field? >>
if (choice == 'Dropdown Select Option 1') {
window.location = 'https://example.com/landingpage1';
} else if (choice == 'Dropdown Select Option 2'){
window.location = 'https://example.com/landingpage1';
} else if (choice == 'Dropdown Select Option 3'){
window.location = 'https://example.com/landingpage2';
} else if (choice == 'Dropdown Select Option 4'){
window.location = 'https://example.com/landingpage3';
} else if (choice == 'Dropdown Select Option 5'){
window.location = 'https://example.com/landingpage4';
}
}
});
</script>
Looking forward to any suggestions/corrections :).
@Peta_APB is your site hosted on Hubspot? I copied this code and tried to use it and nothing happened. It turned out that it was because Hubspot it my CMS so we had to make changes. Happy to share if that helps.
Hi @anders_grove , thanks for the reply. Yes catagory spelt incorrectly but this error was because when the contact property was created it was done with a typo....hence the internal name is unable to be changed..... So I presume I use the internal name for the form field name?
And @ljschwabtx thanks for the reply as well and yes this is going to be used on a Hubspot landing page, however I am even testing on a ClickFunnels landing page and it's just not working. Are you able to share what changes you made to get this to work?
This is a must. Pushing customers to appropriate landing pages based on an a selection is fairly basic. Grant us the ability to utilize "Thank You Code" and expose the form variables to that code so we can dynamically redirect customers via javascript.
I tried using the code but have found that the contact/form information is not consistently making its way to Hubspot nor are we getting notified of the form submission. The redirect is happening faster than the info is getting into Hubspot and then it's getting lost.
Hubspot suggested changing onFormSubmit to onFormSubmitted, but that didn't redirect at all.
We've gone back to our original solution, which was using PlusThis SmartLinks.
My name is Joe, I'm the Ideas Forum Manager. I wanted to thank you for your thoughtful comments on this post. Your feedback helps us build better products.
I think this a great Idea! I'm happy to say we are currently reviewing this request and its feasibility. At this time I don’t have any details around timing or delivery, but all updates will be relayed on this thread.
I am changing the status of this idea to Being Reviewed as our team scopes out this work.
I am looking into this, we have a dropdown for Roles, and i want to redirect the Consumer to a page, while the rest of the roles get a thank you message.
I am not even sure how to go bu this, and i tried Anders's form but it's not working at all.
We need this! It's really unfortunate that this idea is not implemented yet. It was posted in 2017. 3 Years Back. Also, an On/Off Button to take care of the forms submissions, like it's there in google forms will be great.
This is quite basic for people running Marketing campaigns for Saas products! Especially when it comes to automating the optimization of paid media by doing it based in the thank you page for qualified leads instead of everybody!
This would work great for a use case I have right now.
Our client has put together a landing page with a third party. We provided a form for the third party to use so that we can track contacts who convert within HubSpot. The form has two different options people can pick for downloadable content to receive - based on which option they pick, we'd like to return a specific Thank You page with that offer.