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

    Child fields are still shown even if parent fields are hidden

    Asked by designisgrowth on October 19, 2015 at 03:56 PM

    Check out this link:

    http://lmclabs.webship.com/client-center/supplies-requisition-forms.html

     

    I have it set up so that it displays products once you click on a service line. The form then displays all the products that have to do with that service line. Once you check mark a product I have a conditional that displays the quantity. The problem that I have is once you deselect the first conditional (the service line) the quantity still shows up and I don't want it to. I have attached images to show what I mean. Thanks for your help!

     

    SELECTED

     

    DESELECTED

     

     

    Page URL:
    http://lmclabs.webship.com/client-center/supplies-requisition-forms.ht<br/>ml

  • Profile Image

    Answered by designisgrowth on October 19, 2015 at 04:55 PM

    Any takers for this one?

  • Profile Image
    JotForm Support

    Answered by EltonCris on October 20, 2015 at 12:22 AM

    That's because the parent field is still filled even if they are hidden that's why the child fields that depends on it are still shown.

    That can be easily resolved by enabling the "Clear On Being Hidden" option on form preferences.

  • Profile Image

    Answered by designisgrowth on October 20, 2015 at 12:40 AM

    Hi EltonCris,

    Thanks for the answer! Do you know where the code to this change is in the source code? I don't want to re-import the source code so if I can just add it manually that would be great.


    Thanks!
    Daniel Villamizar

  • Profile Image
    JotForm Support

    Answered by EltonCris on October 20, 2015 at 01:45 AM

    Sure, that's possible. The script is already on your form source code, you just have to enable it.

    Simply find this code on your form source code JotForm.clearFieldOnHide="disable"; and change disable to enable.

    Example:

  • Profile Image

    Answered by designisgrowth on October 20, 2015 at 09:18 AM

    EltonCris,
    Thanks! That worked out perfectly. You guys are the best!

    ~ Daniel Villamizar

  • Profile Image
    JotForm Support

    Answered by BJoanna on October 20, 2015 at 11:25 AM

    On behalf of my colleague, you are welcome.

    Feel free to contact us if you have any other questions.