How can I make my jotform fit my mobile device?

  • Profile Image
    roygoli
    Asked on February 16, 2016 at 10:48 PM

    Hi,

    I was wondering how to make my jot form fit the screen of my mobile device when I embed it onto my tumblr.  I already tried using iFrame which didn't seem to work.  I also switched all of my options to "responsive".  It definitely seems possible because the form looks perfect when the jotform link provided is used on a mobile device.  However, when the form is embedded onto my blog, it seems to exceed the screen resolution limit.  

    Embedded code: 

    <script type="text/javascript" src="https://form.jotform.com/jsform/60447354750153"></script>

    iFrame code: 

    <iframe id="JotFormIFrame" onload="window.parent.scrollTo(0,0)" allowtransparency="true" src="https://form.jotform.com/60447354750153" frameborder="0" style="width:100%; height:539px; 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; } var isJotForm = (e.origin.indexOf("jotform") > -1) ? true : false; if(isJotForm && "contentWindow" in iframe && "postMessage" in iframe.contentWindow) { var urls = {"docurl":encodeURIComponent(document.URL),"referrer":encodeURIComponent(document.referrer)}; iframe.contentWindow.postMessage(JSON.stringify({"type":"urls","value":urls}), "*"); } }; if (window.addEventListener) { window.addEventListener("message", handleIFrameMessage, false); } else if (window.attachEvent) { window.attachEvent("onmessage", handleIFrameMessage); } if(window.location.href && window.location.href.indexOf("?") > -1) { var ifr = document.getElementById("JotFormIFrame"); var get = window.location.href.substr(window.location.href.indexOf("?") + 1); if(ifr && get.length > 0) { var src = ifr.src; src = src.indexOf("?") > -1 ? src + "&" + get : src + "?" + get; ifr.src = src; } } </script>

     

    Thank you!

     

  • Profile Image
    Kiran
    Answered on February 17, 2016 at 07:37 AM

    It seems that the form provided here has been deleted. I've checked the other two forms in your account and see that the forms are mobile responsive. Could you provide us with the URL of the webpage where the form is embedded so that we can take a look to investigate the issue?

    We will wait for your response. Thank you!