Can you see any reason why this modifying the HubSpot form embed script this way would interfere with how HubSpot receives the data upon submission?
For whatever reason, when I use this method on a Firefox browser the contact is not passed back to HubSpot. Chrome and Safari both function as intended. The default (non-modified) script works fine in Firefox. All are standard browsers with default configurations, *not* in incognito.
<!--[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: “xxxxxxxx”,
formId: “xxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx”,
inlineMessage: ‘Just a moment please’,
onFormSubmit: function($form){
setTimeout( function() {
var formEmail = $form.find(‘input[name=“email”]’).val();
window.location = “https://www.xxxxx.com/xxxx/?email=” + encodeURIComponent( formEmail );
}, 100 ); // Redirects to url with query string data from form fields after 100 milliseconds.
}
});
</script>
Thank you!