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

    Passing DateTime value from one form to another

    Asked by OSTA2015 on August 23, 2016 at 02:50 PM

    i was wondering if you can pass date and time from one form, i am using the DateTime found in the quick fields for both forms but the second form i have made the fields to be manual inputted but i am still having problems getting the info there as it is putting a totally different date then what i select on the first form to be passed

    date time one form another from one form
  • Profile Image
    JotForm Support

    Answered by jonathan on August 23, 2016 at 05:51 PM

    Yes you can. Use the prepopulate URL method. 

    The DateTime field field name have this format

    {fieldname:month}, {fieldname:month}, {fieldname:year}

    Example form:  https://form.jotform.com/62356373857971

    https://form.jotform.com/62356364639969?date2[month]={date1:month}&date2[day]={date1:day}&date2[year]={date1:year}

    the 2nd form will be populated with value from the 1st form.

     

     

    it work like this

    Hope this help. Let us know if it did not work for you

  • Profile Image

    Answered by OSTA2015 on August 24, 2016 at 10:46 AM
    I am getting the day and year to appear but the month is not coming across for some reason into the second form.

    Here is what I have in form 1

    https://form.jotform.com/60945190292256?submissionId={submissionId}&date2[month]={date1:month}&date2[day]={date1:day}&date2[year]={date1:year}


    this is the email response I get once I submit the from and I can see the month in it but the form is not showing it

    https://form.jotform.com/60945190292256?submissionId=18&date2[month]=08&date2[day]=24&date2[year]=2016

    this is what I end up with in from two after I submit form 1




    Thanks

    Chris Krbavac
    Systems Coordinator
    Ottawa Student Transportation Authority
    Confederation Education Centre, Suite 102
    1645 Woodroffe Ave
    Ottawa, ON K2G 1W2
    613-224-8800 ext 2599
    Mobile: 613-807-7133

    ...
  • Profile Image
    JotForm Support

    Answered by Kevin_G on August 24, 2016 at 12:21 PM

    You're currently using "date2" as your date field, but I have checked it and I can see the name is "date2127" this may the the reason why you're not getting the date completely.

    So the link should be like this: 

    https://form.jotform.com/60945190292256?date2127[month]={date2127:month}&date2127[day]={date2127:day}&date2127[year]={date2127:year} 

    But this seems to be the second form, could you please provide us the first form, the one where you're capturing the data.

    Basically, you need to get the fields names that you want to get the data and send via the URL, this guide will help you with that: How-to-find-field-IDs-and-names

    May be that the name is different for the date field in the first form than the second one, for example, the name for the date field in the first form could be "date1" and in the second form it could be "date2".

    What you need to do it, first get the values from the first form, so it should be:

    {date1:month}

    {date1:day}

    {date1:year}

    Now, set these values for the field in the second form, so it should be:

    date2[month]

    date2[day]

    date2[year]

    Please do note that with "fieldName[Name]" you set the value and with "{fieldName:Name}" you capture the value.

     Hope this helps. 

  • Profile Image

    Answered by OSTA2015 on August 24, 2016 at 01:45 PM
    You are right about the name changing,
    the odd part it I have seen it change a few times from what I thought it was and then go back and it is something else. Why would this happen ?

    Thanks

    Chris Krbavac
    Systems Coordinator
    Ottawa Student Transportation Authority
    Confederation Education Centre, Suite 102
    1645 Woodroffe Ave
    Ottawa, ON K2G 1W2
    613-224-8800 ext 2599
    Mobile: 613-807-7133

    ...
  • Profile Image
    JotForm Support

    Answered by Kevin_G on August 24, 2016 at 02:07 PM

    I have moved your question to a separated thread Chris, as it is not related to this thread, it can be found here: https://www.jotform.com/answers/914867 

    We will assist you on that thread as soon as possible.