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

    Margin for specific Static Text and Number fields

    Asked by GranvilleRefs on January 21, 2017 at 02:06 AM

    Hi,

    I would like to format page 6 in my form for a more presentable grouping. This means reducing top/bottom margins for some specific fields.

    https://form.jotform.co/70134945517861 

     

    This is what it looks like now:

    This is what I want it to look like (I have edited the image):

     

    I have injected this CSS code:

    #text_127{margin-bottom:1px !important;}

    #text_128, #text_130{

      margin-top:1px !important; 

      margin-bottom:1px !important;

    }

    #input_129, #input_134{

      margin-top: 1px !important;

      margin-bottom:1px !important;

    }

    But this hasn't changed anything. How can I get th margins changed?

  • Profile Image

    Answered by GranvilleRefs on January 21, 2017 at 04:23 AM
  • Profile Image
    JotForm Support

    Answered by Welvin on January 21, 2017 at 10:50 AM

    You can use negative values in the CSS, then add !important declaration to override the existing CSS codes (if there's one):

    li#id_127 {

        margin-bottom: -30px !important;

    }

    li#id_128 {

        margin-bottom: -26px !important;

    }

    li#id_129 {

        margin-bottom: -26px !important;

    }

    li#id_132 {

        margin-bottom: -30px !important;

    }

    li#id_137 {

        margin-bottom: -30px !important;

    }

    li#id_138 {

        margin-bottom: -30px  !important;

    }

    li#id_139 {

        margin-bottom: -30px !important;

    }

    li#id_140 {

        margin-bottom: -30px !important;

    }

    li#id_146 {

        margin-bottom: 18px !important;

    }

    Here's the result:

  • Profile Image

    Answered by GranvilleRefs on January 22, 2017 at 02:20 AM

    Thank you.