Populating forms

  • Profile Image
    jranney
    Asked on April 16, 2011 at 01:23 PM

    I understand how to pre-populate a form via url, however, the values have to be entered manually in a link. Is there a way to take the completed fields on one form and have them prepopulate another form when the user clicks submit?

    What I am trying to do is call up alternate forms depending on the conditions of the first form - so how do we get the entries from the first form to the fields of the seconds form.

     

    Thanks,

     

    John Ranney

  • Profile Image
    DanielGriffin
    Answered on April 16, 2011 at 06:43 PM

    Hi John,

    Unfortunately there isn't any easy way to do what you need.  However it is possible using a combination of conditions and your own custom thank you pages.  Basically you would set up some custom thank-you pages which include the entire source code for a second form.  Prepopulating parameters such as ?test={test} wont work because the value of {test} isn't known; so you would need to POST the form data to that second form and collect it using some webcode.  Then set the values of the fields in the second form by writing them out. So,

    1. Set up all the (secondary) forms for the custom thank you pages and embed them into pages on your site.

    2. All of your secondary forms will need to accept the form data.  Have a look at this page for an example of how to do that.

    http://www.w3schools.com/php/php_post.asp

    3. Set up conditions in the conditions wizard to go to a specific form after submission, based on the value of some fields.

     

    4.  Enable sending of POST data on your primary form:

    https://www.jotform.com/answers/2696-WHat-is-send-post-data-

     

    Now when someone submits a form the thank you page will be a second form, prepopulated with information from the first one... it'll be tricky to do so I'd advise getting a developer to handle it for you if you are not comfortable programming.  But get back to me if you need to and I'll help as best I can from here.

    Thanks,

    Daniel