How can I reduce the height of the iframe where my form is embedded?

  • Profile Image
    Asked on January 30, 2015 at 05:36 PM


    Our form is great but when we embed it into our site the height is extreme and it cannot be changed. This seems to be an issue only with the iframe embedding. When we embed the source code this problem with the height goes away. Please let me know if there is anything you can do to fix it. Here is the form on the site.


    -Nick Gamber

  • Profile Image
    Answered on January 30, 2015 at 06:33 PM

    Please try to only use the following embed code:

    <iframe id="JotFormIFrame" onload="window.parent.scrollTo(0,0)" allowtransparency="true" src="" frameborder="0" style="width: 100%; height: 800px; border: none;" scrolling="no"></iframe>

    In other words please also remove this part:

    <script type="text/javascript">window.handleIFrameMessage = function(e) {var args =":");var iframe = document.getElementById("JotFormIFrame");if (!iframe)return;switch (args[0]) {case "scrollIntoView":iframe.scrollIntoView();break;case "setHeight" = args[1] + "px";break;case "collapseErrorPage":if (iframe.clientHeight > window.innerHeight) { = window.innerHeight + "px";}break;case "reloadPage":window.location.reload();break;}};if (window.addEventListener) {window.addEventListener("message", handleIFrameMessage, false);} else if (window.attachEvent) {window.attachEvent("onmessage", handleIFrameMessage);}</script>

    You can adjust the height value directly to make the iframe fit your website.

    Let us know if this helps.
    Thank you.

  • Profile Image
    Answered on January 30, 2015 at 06:40 PM

    I have asked questions on here with no answer?

  • Profile Image
    Answered on January 30, 2015 at 07:06 PM


    We apologize for any delay in providing a response to your questions, we're actively working on providing answers to all the questions in the forum.

    Rest assure that we'll provide you with a response to each of your questions as soon as we can.

    We appreciate your patience.
    Thank you.