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

    Using API collect data from database and autofill the form

    Asked by mandarpatil09 on June 24, 2014 at 08:43 AM

    Is it possible in API?

    to prepopulate with the data in it?

  • Profile Image
    JotForm Support

    Answered by ashwin_d on June 24, 2014 at 09:37 AM

    Hello mandarpatil09,

    Unfortunately, there is no API to read data from your own database and then pre-populate your form fields.

    The only way I can currently think writing your own code to read data from your own database. If you have programming experience, here are the steps you should follow:

    1. Create a web page (PHP/ASP.Net).

    2. Write your own code to connect to your own database and fetch the data from the table.

    3. Read the values and then build a string using string builder class or similar.

    4. You need to basically create an URL parameters for your form to pre-populate field. The string which needs to be build is to concatenate the form fields and pass the database value in the corresponding form fields separating by "&" character. Ex: "fieldname=databaseValue&" and so on for all field.

    The following guide should help you get your form field's name:  http://www.jotform.com/help/146-How-to-find-Field-IDs-Names

    The following guide should help you understand the URL parameter features:  http://www.jotform.com/help/71-Prepopulating-fields-to-your-JotForm-via-URL-parameters

    5. Once you have built your URL parameters string, you need to concatenate your form URL and redirect to this string.

    Hope this helps.

    Do get back to us if you have any questions.

    Thank you!