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

    Date time freezing on mobile and tablet

    Asked by FloridaDreamHomes on May 11, 2016 at 06:40 PM

    I have two date time fields in my form, where the arrival date and departure date need to be input. The dates that started causing us a problem are arrival 12/22/2016 with a departure on 1/04/2017.

    Date time field works fine. I operate the calendar, and select the proper dates. However, when I try to select the departure date, when scrolling forward month by month, it freezes on mobile and tablet. I generally get to around September 2016, and then it freezes.  I have tried setting the date time fields to lite, that didn't help.

    I was able to get it to not freeze by pusing the forward one year button when selecting the departure date, and then back-tracking to January, but that isn't an option usable for everybody, as there will be tech unfriendly people utilizing the form.

    Note: the issue only occurs when working from a mobile device like a tablet or phone. On the computer, the date select works just fine. Any help you could provide would be much appreciated.

     

    Mobile date time freezing
  • Profile Image
    JotForm Support

    Answered by BDAVID on May 11, 2016 at 07:21 PM

    I just tried it, and it did not freeze:

    Please try the following:

    1) Clear your forms cache: https://www.jotform.com/help/229-How-to-Clear-Your-Form-Cache

    2) Embed your form using the Iframe code: https://www.jotform.com/help/148-Getting-the-Form-iFrame-Code 

    Before you embed the code, paste it in a text editor like WordPad, you will notice two part of codes, only copy and embed the Iframe part in your webpage, example:

    Make sure to set the proper height in you Iframe code to display all your form. Let us know if you need more help.

  • Profile Image

    Answered by FloridaDreamHomes on May 12, 2016 at 12:32 PM

    I only had the issue when physically on my android phone, or physically on one of our clients Ipad. It looks like in the attached GIF, you are using a virtual device. When I test it on the computer, it works beautifully.

    I had it embedded via the embed code. What's the benefit to embed it as an Iframe? I tried putting it as an iframe (making sure to only grab the iframe code, and not the script afterward), and still ran into the issue on my phone. Admittedly, it worked the first time, but when I refreshed the phone to give it another try to make certain, it froze when inputting the departure date, freezing at November.

    I cleared the form cache, and it didn't fix the issue. I still go in on my phone, and it freezes when inputting the departure date. Note: I always input the arrival date first, then the departure date. I am using the form the same way the average user would.

  • Profile Image
    JotForm Support

    Answered by Boris on May 12, 2016 at 01:58 PM

    The iFrame embed method helps eliminate almost all kinds of possible scripting conflicts between the scripts of the website and the scripts within the form - providing the best environment for the form to run.

    I see that the form embedded on your website is form:

    https://form.jotform.com/60646355309155

    I have tested that form on my own Android device, and I could instantly recreate the issue - it is caused by the conditions which are set for your arrival/departure fields:

    These two conditions are creating an endless loop, something that results in incalculable result:

    IF departure AND arrival are filled, insert a number into "number of nights"

    IF "number of nights" is greater than 0, insert 0 back into the departure field

    As soon as 0 is entered back into the departure field, it again triggers the first condition, which will insert some number again into the "number of night". Then the second condition is triggered again, than the first condition, then second condition, and so on. An endless incalculable loop.

    Our forms have an inbuilt protection against endless loops, where a conditions simply gives out after a certain number of tries. Desktop computers are an order of magnitude more powerful than mobiles, so they figure out rather quickly that it is a loop and simply give out calculating that condition.

    Mobile phones are much weaker in computing power, so it takes them a very long time to figure out it is an endless loop, therefore taking more time for the condition to forcefully stop calculating.

    I have confirmed that this was indeed the case by simply disabling the conditional rule that was creating the endless loop:

    As soon as I have done that, my Android device could instantly switch through the months of the Date Time calendar popup.

    Please try disabling that condition on your form, and let us know if you need any further assistance. We will be happy to help.

  • Profile Image

    Answered by FloridaDreamHomes on May 12, 2016 at 04:07 PM

    Thank you for your help, that did the trick.

    During an old iteration of the form, that was used to stop the user from inputting a departure date that was earlier than the arrival date. However, that was already being taken care of by the formatting on a different field (number of nights needing to be positive).

    I wish there was a way to link it up so that once the arrival date was selected, when you clicked the departure date, it would open the calendar at the arrival date, but I couldn't figure out a solution that didn't result in script crashing, or making the departure date stuck at the arrival date. It's not imperative though, it just saves the user a few clicks.

  • Profile Image
    JotForm Support

    Answered by BDAVID on May 12, 2016 at 04:29 PM

    On behalf of my colleague, you are welcome. On regards of your second inquiry, unfortunately there is no way to pop up the calendar based on another fields input or selection.