Lead Capture Tools

MarkCCC
Member

Redirect to URL after submitting Hubspot form not working

Hi everyone, 

After strolling through a lot of the posts already to try to find a solution to my problem, i couldn't and hope someone can help please as I am not very technical at all. Feels like the issue is to do with either HTML code or my website. 

 

I've created a hubspot form and embedded on my website (https://contextcapital.com.au/old-publications) via HTML code. When i tested it by submitting the form on my website and hit the submit button, nothing happens. It does not redirect the browser to the URL i specify on hubspot. it just stays on the that page. it does create a new contact in hubspot as intended. The purpose of this is after website visitors submit the details on the form, it redirects them to this page (https://contextcapital.com.au/publications-download) to download papers. this page is hidden on the website but it works.  the website is hosted by Godaddy.

i've tried clearing caches and cookies, incognito tab and different browser but the form won't redirect to the intended URL.

 

Any help is appreciated. 

Thanks, Mark

5 Replies 5
crbarnett
Member

Redirect to URL after submitting Hubspot form not working

Hi,
Embedded form appears on the page and can be filled out. https://salesgrowth.com/learn-to-create-email-that-actually-get-opened/

Upon submit there is no page redirect, the submission is not logged in Hubspot, and the user does not receive automated confirmation email with downloadable asset attached.

The rendered code in viewsource is identical to what was copied form the sharing feature on the edit form page in Hubspot.

I tried the troubleshooting tips from this knowledgebase article: https://knowledge.hubspot.com/forms/why-doesn-t-my-externally-embedded-hubspot-form-work

Also tried adding https:// to the beginning of this js reference... src="//js.hsforms.net/forms/v2.js"

Code copied from HS:
<script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/v2.js"></script>
<script>
hbspt.forms.create({
region: "na1",
portalId: "166003",
formId: "d7ad2957-d05e-4e33-91dc-7617ec61561a"
});
</script>


And what rendered code on the page looks like: (no iframes)

<div class="et_pb_module et_pb_code et_pb_code_0">
<div class="et_pb_code_inner">
<script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/v2.js"></script>
<script>
hbspt.forms.create({
region: "na1",
portalId: "166003",
formId: "d7ad2957-d05e-4e33-91dc-7617ec61561a"
});
</script>
</div>
</div>

https://www.loom.com/share/ec8d541f7821444ca1a493febd9ae968
Video of what's happening ^^^

Any thoughts on what might be wrong?
@tjoyce @Jake_Lett 

0 Upvotes
MarkCCC
Member

Redirect to URL after submitting Hubspot form not working

thanks @tjoyce for the explanation but appreciated if someone can take a look at the embedded code below and advise how to get around the iframe within an iframe issue as i am not tech savvy with codes. tried contacting godaddy support but no luck. they are pushing the issue with the form not the website and unwilling to troubleshoot. thanks

 

<script charset="utf-8" type="text/javascript" src="//js.hsforms.net/forms/shell.js"></script>
<script>
hbspt.forms.create({
region: "na1",
portalId: "7811008",
formId: "c988472b-3dbc-4430-b335-341714697055"
});
</script>

tjoyce
Recognized Expert | Elite Partner
Recognized Expert | Elite Partner

Redirect to URL after submitting Hubspot form not working

@MarkCCC - This issue is caused because your HS embed code into an iframe. Your form is going to render in an iframe as well. 
I have previously answered a similar question here https://community.hubspot.com/t5/Lead-Capture-Tools/Hubspot-Form-Not-Redirecting-To-URL/m-p/414214

webdew
Guide | Diamond Partner
Guide | Diamond Partner

Redirect to URL after submitting Hubspot form not working

Hi @MarkCCC ,

You can check this article here- https://community.hubspot.com/t5/Tips-Tricks-Best-Practices/Troubleshooting-non-HubSpot-Forms/td-p/...

that goes through the steps as to why it is not collecting

 

One common reason is that the tracking code has not been installed correctly on the website so I would recommend you to go to the page and troubleshoot if the hubspot tracking code is firing.

 

Hope this helps!


If we were able to answer your query, kindly help the community by marking it as a solution.

Thanks and Regards. 

0 Upvotes
TiphaineCuisset
Community Manager
Community Manager

Redirect to URL after submitting Hubspot form not working

Hi @MarkCCC 

 

Thank you for reaching out.

 

I'm wondering if this could come from a conflict with some javascript. I want to tag some of our experts on this - @tjoyce @Jake_Lett @Alex_ do you have any thoughts for @MarkCCC on this? 

 

Thank you!

Best

Tiphaine


Saviez vous que la Communauté est disponible en français?
Rejoignez les discussions francophones en changeant votre langue dans les paramètres !

Did you know that the Community is available in other languages?
Join regional conversations by changing your language settings !