Embedding using the Iframe code - the form gets cut off when hidden fields are revealed

  • Profile Image
    Asked on August 13, 2014 at 06:16 AM

    I've embedded using iFrame but I've had to turn scrolligng on in the html as it get cut off if you select company.  Is there any way to make th iframe longer?  I've tried various things in the html but don't really know what I'm doing as the website was written in serif webplus.

  • Profile Image
    Answered on August 13, 2014 at 10:26 AM

    Please try re-embedding the iframe but this time do not include the <script> </script> as when including those the height that you apply does not work.

    By removing the script section in the iframe code this should set a fix height. Sample of your iframe code below. Remove the one that has a strikethrough.

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

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