HTML5 widget not showing up

Hello! I am new to Hype.
I love this product. But I run into one issue.
I am trying to add Hubspot form with HTML5 widget but it isn’t showing up.
What am I doing wrong?

What is the HTML code that Hubspot gives you? Can you attach a document with your attempt?

<!--[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: '412070',
    formId: 'bf3469a5-69f3-4f91-a72a-d56e9c3fd860'
  });
</script>

this is a code. it won’t let me upload

Copy this:

<!--[if lte IE 8]>
<script charset="utf-8" type="text/javascript" src="https://js.hsforms.net/forms/v2-legacy.js"></script>
<![endif]-->
<script charset="utf-8" type="text/javascript" src="https://js.hsforms.net/forms/v2.js"></script>
<script>
  hbspt.forms.create({ 
    portalId: '412070',
    formId: 'bf3469a5-69f3-4f91-a72a-d56e9c3fd860'
  });
</script>

Replace
src="//js. with
src="https://js.

That will ensure that your form JavaScript actually loads from the web. With just // your code is trying to load from your local machine when previewing in Hype.

Thank you. I did that, but nothing happened

It looks like it needs a bit more of a wrapper around it. Here’s the code I used within the inner HTML of a HTML Widget:

<!DOCTYPE html>
<html>
<head>
	<title></title>
</head>
<body>
<!--[if lte IE 8]>
<script charset="utf-8" type="text/javascript" src="https://js.hsforms.net/forms/v2-legacy.js"></script>
<![endif]-->
<script charset="utf-8" type="text/javascript" src="https://js.hsforms.net/forms/v2.js"></script>
<script>
  hbspt.forms.create({ 
    portalId: '412070',
    formId: 'bf3469a5-69f3-4f91-a72a-d56e9c3fd860'
  });
</script>
</body>
</html>

hubspotform.zip (11.0 KB)

1 Like

this worked beautifully! thank you very much

1 Like