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

    How to modify a form field script to make it Required

    Asked by elehmann81 on April 08, 2013 at 12:59 PM



    I have a an existing "JotForm" For on my website and I'd like to change one of the existing fields to be required.  There are customized sizes, layouts, etc in place and Ideally I'd like to do this wihtout creating a completely new form.  Is there a simple coding change that'll accomblish that.  Hopefully I don't have to start from scratch.  I'd like to require the email field.  Here's the exisitig code:  Thanks, Eli

    <li class="form-line" id="id_7">
      <label class="form-label-left" id="label_7" for="input_7"> Email: </label>
      <div id="cid_7" class="form-input">
      <input type="text" class="form-textbox" id="input_7" name="q7_email" size="31" />


    Page URL:

  • Profile Image

    Answered by KadeJM on April 08, 2013 at 01:38 PM

    The easiest way to do this would be to turn ON the " Requirement " in your form and then re-embed it with the changes you've made.

    However, if you are looking for a way to rescript this via the form's source code you can change out the Input Script -



     <li class="form-line" id="id_3">

            <label class="form-label-left" id="label_3" for="input_3"> Full Name: </label>

            <div id="cid_3" class="form-input">

              <input type="text" class=" form-textbox" id="input_3" name="q3_fullName" size="25" />





    <li class="form-line" id="id_3">

            <label class="form-label-left" id="label_3" for="input_3"> Full Name:<span class="form-required">*</span>


            <div id="cid_3" class="form-input">

              <input type="text" class=" form-textbox validate[required]" id="input_3" name="q3_fullName" size="25" />



    You will need to replicate this for the other fields as well to make them take on the Requirement. I have highlighted the scripting that needs to be added to the field scripts to allow this to happen.


  • Profile Image

    Answered by elehmann81 on April 08, 2013 at 01:43 PM

    This is tremendously helpful.  Thanks!  I'm guessing I'd only need to make these additions to the individual fields I'd like to be "required", and can avoid changing codes on ones that I'm not concerned about.  Is that correct?  Thanks again, Eli

  • Profile Image

    Answered by KadeJM on April 08, 2013 at 02:01 PM

    No problem Eli, you are very welcome, and yes that is correct. But if you run into any issues just let us know and we'll help you to get it corrected.

  • Profile Image

    Answered by elehmann81 on April 08, 2013 at 02:05 PM

    It appears to be working for me: http://www.casadoshermanos.com/rates/booknow.html

    Can't tell you helpful that was.  It's tremendously frustrating to get reservation requests from people and not have a way to contact them.  A small oversite initially, but always been too much trouble to fix.  Thanks again for your help.

  • Profile Image

    Answered by sidharth_kch on April 08, 2013 at 02:10 PM


    Glad to know that your issue was resolved.

    Should you have any questions feel free to contact us.



  • Profile Image

    Answered by Cameron on August 20, 2013 at 02:33 AM

    Hi guys,

    please can you help me?

    I have this email form and I want to make mandatory fields throughout the form. I have the names of the input fields in the input areas themselves.

    how can I get this right? in any suggestions are greatly appreciated



  • Profile Image

    Answered by gori-mathew on August 20, 2013 at 03:32 AM

    Hi Cameron,

    You can alternatively set the fields as required through the Jotform form builder. As shown in the snapshot below select the field and then click on the fields properties and select the required button to set the field as required.

    Do let us know if you need further assistance.