ando_337 Posted December 18, 2020 Share Posted December 18, 2020 (edited) Hi, I want to embed a zoho form on my landing page. Unfortunately, I can't use iframe because in the mobile view the form is cut off. I would like to try it with JavaScript but I can't insert the code in the code block - it appears simply as code (see screenshot). Who knows what to do? This is the code I wand to embed: Quote <div id="zf_div_EuPWAJbU6VZQc1E1HHbrEpXtqYfrcVNPG_u-zsP9TtI"></div><script type="text/javascript">(function() { try{ var f = document.createElement("iframe"); f.src = 'https://forms.zohopublic.eu/inneco/form/Neugierig/formperma/EuPWAJbU6VZQc1E1HHbrEpXtqYfrcVNPG_u-zsP9TtI?zf_rszfm=1'; f.style.border="none"; f.style.height="500px"; f.style.width="90%"; f.style.transition="all 0.5s ease";// No I18N var d = document.getElementById("zf_div_EuPWAJbU6VZQc1E1HHbrEpXtqYfrcVNPG_u-zsP9TtI"); d.appendChild(f); window.addEventListener('message', function (){ var zf_ifrm_data = event.data.split("|"); var zf_perma = zf_ifrm_data[0]; var zf_ifrm_ht_nw = ( parseInt(zf_ifrm_data[1], 10) + 15 ) + "px"; var iframe = document.getElementById("zf_div_EuPWAJbU6VZQc1E1HHbrEpXtqYfrcVNPG_u-zsP9TtI").getElementsByTagName("iframe")[0]; if ( (iframe.src).indexOf('formperma') > 0 && (iframe.src).indexOf(zf_perma) > 0 ) { var prevIframeHeight = iframe.style.height; if ( prevIframeHeight != zf_ifrm_ht_nw ) { iframe.style.height = zf_ifrm_ht_nw; } } }, false); }catch(e){} })();</script> Edited January 2, 2021 by ando_337 Beyondspace 1 Link to comment
Beyondspace Posted December 19, 2020 Share Posted December 19, 2020 16 hours ago, ando_337 said: Site URL: https://www.inneco.de/eco-basic-eco-premium Hi, I want to embed a zoho form on my landing page. Unfortunately, I can't use iframe because in the mobile view the form is cut off. I would like to try it with JavaScript but I can't insert the code in the code block - it appears simply as code (see screenshot). Who knows what to do? This is the code I wand to embed: Uncheck the first rectangle and turn the downdown to HTML creedon 1 Greeting, it's BeyondSpace, I am Squarespace dev focus on provide solutions to enhance feature that squarespace.com can't provide.Feel free to check my current Squarespace Plugins Developement: Enable Pinch/Zoom on lightbox, Delivery Date Picker, Lightbox Studio pluginIf you find my answer fit your need, let's leave a like or upvote so others with the same issue can find their solution. Thank you Link to comment
ando_337 Posted December 19, 2020 Author Share Posted December 19, 2020 @bangank36 I did, but than it says script disabled: Link to comment
Beyondspace Posted December 19, 2020 Share Posted December 19, 2020 1 minute ago, ando_337 said: @bangank36 I did, but than it says script disabled: Script disabled in editor mode, it run on live site, did you have business plan Greeting, it's BeyondSpace, I am Squarespace dev focus on provide solutions to enhance feature that squarespace.com can't provide.Feel free to check my current Squarespace Plugins Developement: Enable Pinch/Zoom on lightbox, Delivery Date Picker, Lightbox Studio pluginIf you find my answer fit your need, let's leave a like or upvote so others with the same issue can find their solution. Thank you Link to comment
ando_337 Posted December 19, 2020 Author Share Posted December 19, 2020 oh! I didn't know that! Thanks a lot - you made my day! Beyondspace 1 Link to comment
SQA Posted February 1, 2022 Share Posted February 1, 2022 (edited) On 12/19/2020 at 4:23 PM, bangank36 said: Script disabled in editor mode, it run on live site, did you have business plan @bangank36 Hi! I am having the same issue with "script disabled" text in editor mode for javascript. I do have business plan and I also selected HTML with same result. Any idea why it doesn't work? Edited February 1, 2022 by SQA Link to comment
paul2009 Posted February 2, 2022 Share Posted February 2, 2022 16 hours ago, SQA said: I am having the same issue with "script disabled" text in editor mode This is correct in editor mode. To view your site with the script enabled, open the site in a new private (or incognito) browser window where you are not logged into the site. You will now view your site as a visitor does, and scripts should run. If this post has helped you, please click a 'Like' or 'Thanks' icon below ⬇️ About: Squarespace Circle Leader since 2017. I value honesty, transparency, diversity and great design ♥.Work: Squarespace Developer and founder of SF Digital, building the features Squarespace didn't include™. Content: Links in my posts may refer to SF Digital products or may be affiliate links. Catch up on all the release notes and announcements 2023 [for Circle members only]. There's a public version here too!If I helped, you can thank me by clicking one of the emojis below. If you prefer, you can buy me a coffee.Improve your online store with our extensions. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment