What is JotForm?
JotForm is a free online form builder which helps you create online forms without writing a single line of code. No sign-up required.

At JotForm, we want to make sure that you’re getting the online form builder help that you need. Our friendly customer support team is available 24/7.

We believe that if one user has a question, there could be more users who may have the same question. This is why many of our support forum threads are public and available to be searched and viewed. If you’d like help immediately, feel free to search for a similar question, or submit your question or concern.


  • Profile Image

    How can I minimize the iframe height of the form

    Asked by moredo66 on April 12, 2015 at 04:28 PM

    I want to minimize my form because it´s to long could you please help me that I can scroll down the form on my page

     

    I think the I-Frame code should be chanced but I don´t know how to do this.

     

    The best size would be 670 x 670

     

    <iframe id="JotFormIFrame" onload="window.parent.scrollTo(0,0)" allowtransparency="true" src="//german.jotform.com/form/50986939075371" frameborder="0" style="width:100%; height:1780px; border:none;" scrolling="no"></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;case "collapseErrorPage":if (iframe.clientHeight > window.innerHeight) {iframe.style.height = 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>

     

    I hope you can help me

     

    Thank´s for a quick reply Peter

     

    P.S. The page is not online I´m just building it.

     

    height iframe
  • Profile Image
    JotForm Support

    Answered by jonathan on April 12, 2015 at 08:22 PM

    Please refer to the user guide -Getting-the-Form-iFrame-Code

     

    You can adjust the height of the iframe in the given embed code

     

    Please inform us if you need further assistance.

    Thanks.