We are trying to help a client resolve a function of their existing site that HubSpot did not transfer over when migrating their site to HubSpot.
Their old site had a modal that opened and showed iFrame content within the opened modal. But HubSpot just set the links to open in a new tab. I was able to use Magnific Popup to handle the modal part and used a custom module to have a text field for entering the button text and a text field for dropping the iFrame URL in. The code snippet for the iFrame URL is where the src would go in the iFrame code.
I have tried just placing the iFrame URL instead of the code snippet, which kind of worked. The iFrame audio plays when you visit the page, but it should not. Then when you click the button, the iFrame is shown in the modal correctly.
So my problem, is what is causing the code snippet to mess up when it is in place?
Preview Link with the LAUNCH OUR VIDEO VIEWBOOK button at the bottom of the page.