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

    Can i export to a data base in mysql?

    Asked by skidzz on March 22, 2011 at 06:42 AM
  • Profile Image
    JotForm Support

    Answered by liyam on March 22, 2011 at 08:04 AM

    Hello,

    It is possible. 

    Manually, you can download your CSV report and export it to your MySQL database. 

    If you want a process done for every submission, you will have to create your own script to do an SQL insert to your database.  Of course, you will need your own Thank You page outside jotform to do the SQL insert query.

    To do this, you will have to set your JotForm to do post action after submission in the options.  This will post all data going to your custom URL Thank You page. 

    How to set your form to do sending post data:

    1. Edit your form and click on Setup & Embed tab

    2. Click on Preferences and a pop-up will appear

    3.  Once the pop-up appears, click on Advanced Settings, you will see on Send Post Data is set to 'No'.  Click on 'No' and it will change to a drop down. 

    4. Select Yes then save it by clicking the Green 'Close Settings' button.

    You're done with configuring your form!

    Now we setup the Custom URL Thank You page.

    1. Click the Thank You link on top

    2.A thank you page wizard will appear, select the Custom URL option and click the Next button

    3. Enter the URL of your site to which will represent as your Thank you page with an SQL insert query

    How to know the data being sent to your Thank you page:

    <?php
    print_r($_POST);
    ?>

    or

    <?php
    var_dump($_POST);
    ?>

    This way you will be able to see the variables related to the values passed.  Now you can use those variables to insert your query inside your thankyou page going to your database.

  • Profile Image

    Answered by allanftd on March 22, 2011 at 08:43 AM

    Hi skidzz,

    The amazing thing about JotForm is that you can perform one task in many ways. It's up to you to choose which one will work best for you.

    The above suggestion by liyam is excellent. An alternative option for you is to export the submissions data found in the Submissions Page into an Excel file. Then import this Excel file into your mysql database.

    Here's the location of the Export to Excel icon in your submissions page:

    We hope these options will be useful for you. Thank you for using JotForm!

    JOTFORM SUPPORT

  • Profile Image

    Answered by lshad24 on November 08, 2011 at 11:43 AM

    I am reading this solution with great interest but need a little more clarification.  I have a database that I use for scheduling appointments.  When an appointment is made, I send a confirmation to the student with the url to a form that the student needs to complete prior to the appointment.  It would be great if after the student completes and submits the form, the form data (pdf preferably) could be added to my database so that when the tutor sees the appointment, the pdf (containing student data) is available. 

    Possible? 

  • Profile Image
    JotForm Support

    Answered by fxr on November 08, 2011 at 06:03 PM

    Its not possible to update a mysql database automatically from a JotForm form submission.

    But you could write some PHP making use Form Post Data in a Thankyou Page with a Custom URL. 

    You may find this guide of some use -> http://www.jotform.com/help/51-How-to-Post-Submission-Data-to-Thank-You-Page

    I added an example of how to the Forms Post Data in one of the replies to the comments near the bottom.

    I see my colleague liyamhas  also explained how to use Form Post Data in his comments above

    Posting to a mysql database with PHP isnt a million miles away from that, but would need a little bit of work on your part. 

    If your Custom URL lives on the same web server as your Mysql database, connecting to it with php would be as simple as something like this:

    http://pastie.org/2833439

    The insert would look something like this:

    http://pastie.org/2833449

    Most of the components you need are in that guide and those little snippets of PHP above.

    I may at some point in the future create a user guide entry in how to insert data from JotForms form submission into a mysql database. I was just thinking about this earlier today as it happens. 

  • Profile Image

    Answered by lshad24 on November 09, 2011 at 10:31 AM

    I look forward to seeing theis user guide entry.  Thanks, fxr

  • Profile Image
    JotForm Support

    Answered by fxr on November 09, 2011 at 04:36 PM

    You'll be amongst the first to know when its done, Ishad.

  • Profile Image
    JotForm Support

    Answered by fxr on November 10, 2011 at 07:50 AM

    Liyam has put together a nice guide for us on posting JotForm data into a Mysql database, which should be some use to you, Ishad24.

    http%3A%2F%2Fwww.jotform.com%2Fhelp%2F126-How-to-Insert-or-update-form-submissions-to-your-MySQL-database-using-PHP

  • Profile Image

    Answered by khrisell on July 04, 2013 at 07:14 PM
    Greetings!

    We are happy to announce that we have released Jotform Webhooks,  this feature would replace Send Post Data + Custom URL Thank You Page workaround in order to help you transfer forms data to your own database using your own script codes.

    To know more about Jotform Webhooks, please click here.

     

    Thank you for using JotForm. :)