Why link in Hype Do Not Work when embedded

Preformatted textHi when I run a hype in browser it has no problem in letting the links be opened. But when I embed into a page the links will not open. What is the problem?

Here is the embed code:

<div style="height: 500px;">
<div id="rufeliwaycathappinessru_hype_container" style="margin: auto; position: relative; width: 100%; height: 100%; min-height: 375px; overflow: hidden;">&nbsp;</div>
<div style="margin: auto; position: relative; width: 100%; height: 100%; min-height: 375px; overflow: hidden;">
<script type="text/javascript" src="https://4368135.fs1.hubspotusercontent-na1.net/hubfs/4368135/ru-feliway-catHappiness_ru/ru-feliway-catHappiness_ru.hyperesources/rufeliwaycathappinessru_hype_generated_script.js" charset="utf-8"></script>
</div>
</div>

Let me know if you need the hype code.

When I put that code into a file and look at the console, I see several errors like:

[Log] Error in undefined: ReferenceError: Can't find variable: jQuery (HYPE-740.thin.min.js, line 84)
[Log] Error in undefined: ReferenceError: Can't find variable: sprayAdviceViewMore (HYPE-740.thin.min.js, line 84)

Chances are that missing jquery is the root culprit, but it would be impossible to know what else is missing. This is typically included in the document head html, not part of the embed snippet. So you probably need to copy/paste additional code that includes the jquery reference (and possibly anything else that you're including there). See the part marked in <!-- copy these lines to your document head: --> in an export .html file to know what to use.

Seems like jQuery is being loaded: Насколько счастлива ваша кошка? Пройдите наш тест!

Also image from head:

If you add this code to your head, it will only be loaded if you export as an HTML file and load that, or if you copy + paste this code into wherever you embed your document. So make sure you copy this code into the page's <head> area.

For your case, you would need to find where you use ${resourcesFolderName}/ and replace this with:
https://4368135.fs1.hubspotusercontent-na1.net/hubfs/4368135/ru-feliway-catHappiness_ru/ru-feliway-catHappiness_ru.hyperesources/

This will load any fonts you have referenced.

1 Like