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

    Pre-populate fields in an Iframe

    Asked by markashton on January 25, 2011 at 08:41 AM

    Hi,

    I cannot get values to pass through a url that reside in an Iframe.

     

    This works: http://www.jotform.com/form/2054052230?firstName=Dave

    This iframe of the same form does not: 

    http://www.workflows.co.uk/temp/prepop.htm?firstName=Dave

    Can anyone help on this I'd be most grateful

    Regards Mark

  • Profile Image
    JotForm Founder

    Answered by aytekin on January 25, 2011 at 10:52 AM

    1. Change the page from ".htm" to ".php"

    http://www.workflows.co.uk/temp/prepop.php?firstName=Dave

    2. Add the variables to the form URL on the page like this:
    ?http://www.workflows.co.uk/temp/prepop.php?firstName=<?=$_GET['firstName']?>&lastName=<?=$_GET['lastName']?>&
  • Profile Image

    Answered by markashton on February 07, 2011 at 06:19 AM

    Hi Ayetkin,

    Couple of problems:

    1) Cannot get this to work with my iframes. Is the syntax correct? Why the question mark at beginning? Is there an example I could see to reverse engineer.

    2) I have a lot of .htm files out in the world and am a little reluctant to have to change them all for clients et al. I use another provider (sometimes) whereby this functionality does work with .htm files.
    So my question is: Is it possible with jotform to pass values through a url to .htm files?

    Many thanks, Regards Mark 

  • Profile Image
    JotForm Founder

    Answered by aytekin on February 07, 2011 at 09:38 AM

    1) That's how you send variables from URL. This is the form:

    URL?param1=value1&param2=value2

    2) Unfortunately, you cannot use PHP code on .htm files. So, this is not possible on those files. 

  • Profile Image

    Answered by Domenic on November 21, 2011 at 06:35 PM

    I am doing somehting similar and would like to know if it is possible to:

    Hit a page with parameters in the URL I.E., ?name=whatever&company=whocares

    and have an iframed form from a different site get populated with the date THEN auto submit?

    There is no user interaction on this form, it is just a backend sysytem that hits a post back page after a phone call happns and passes that data to the page. The issue is the form is on a third party system and I have no control of the code, just the form creation.

  • Profile Image
    JotForm Support

    Answered by fxr on November 21, 2011 at 07:25 PM

    Domenic,

    I really dont think this functionality is possible, but if you want to pursue it, please open a new thread and detail exactly what you are trying to achieve and we can certainly have a think about what your options are. 

    Thanks.

  • Profile Image

    Answered by markashton on November 22, 2011 at 05:04 AM

    Domenic,

    It is possible - but not through Jotform. However, there is a solution through jotform. Instead of using an Iframe ... use the embed function with script. You will then be able to reproduce exactly the same scenario.

    Look here: link removed

    Iframe ... check the source and you will see that I have just embedded the script.

    Voilla ;) (Send me the cash in a brown bag ;)

  • Profile Image

    Answered by novacoast on February 22, 2013 at 05:22 PM

    Are these ideas still valid?  they are a few years old and the most recent post doesn't seem to work anymore.

  • Profile Image
    JotForm Support

    Answered by jonathan on February 22, 2013 at 05:49 PM

    @novacoast

    Hi, can you please clarify which one does not work? 

    The pre-populate fields still works. You may want to review this guide: Prepopulating-the-fields-to-your-JotForm-via-URL-parameters

    It would be better also if you could create your topic (use this), so we can easily focus on your inquiry.

    Thanks.

  • Profile Image

    Answered by lstreak on April 01, 2013 at 04:00 AM

    Hi, can someone help me out this?

     

    I'm iframing this site in my own parent page, how can i have the fields in the iframe pre-populated?

     

    Thanks in advance.  Sorry if this has been answered b4, but please someone please clarify how it can be done. Thanks again.

  • Profile Image
    JotForm Support

    Answered by EltonCris on April 01, 2013 at 05:34 AM

    @lstreak,

    It's explained on this guide: Prepopulating the fields to your JotForm via URL parameters

    So if you are using iframe embed code, you can append the URL parameters on the JotForm URL. Example:

    <iframe allowtransparency="true" src="//form.jotformpro.com/form/30771202081947?fullName3[first]=John&fullName3[last]=Doe" frameborder="0" style="width:100%; height:562px; border:none;" scrolling="no"></iframe>

    Let us know if you have further questions. Thanks!