PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

adding a box around a group of fields

  1. rd458
    Member

    I haven't been able to figure out how to apply something like a 1px border around several fields, in order to create some level of separation on a bigger form with lots of fields. For instance:

    -------
    field 1 |
    field 2 |
    field 3 |
    -------

    -------
    field 4 |
    field 5 |
    field 6 |
    -------

    Do I add an HTML section with a div, and then another HTML section to close the div, then use CSS to style the div?

    Posted 10 years ago on Tuesday June 11, 2013 | Permalink
  2. Richard Vav
    Administrator

    Yes that's what I have done previously, so you would add a HTML field to the top of your group adding the following content for example

    </li>
    </ul>
    <div class="my-box-style">
    <ul class="gform_fields top_label description_below">
    <li>

    Then between your first and second group you would add another HTML field with the following content for example

    </li>
    </ul>
    </div>
    <br />
    <div class="my-box-style">
    <ul class="gform_fields top_label description_below">
    <li>

    and then at the bottom you would add another HTML field with the following content for example

    </li>
    </ul>
    </div>
    <ul>
    <li>

    You would have to make sure the ul classes match your form settings so your labels and descriptions appear in the correct places.

    Regards,
    Richard

    Posted 10 years ago on Tuesday June 11, 2013 | Permalink
  3. rd458
    Member

    Great solution Richard. Thanks for sharing. The part I couldn't figure out was that I had to end the list-item and unordered-list before placing my div, and then follow the div by a new li and ul. It worked perfectly and my fields are neatly organized now. Thanks again.

    Posted 10 years ago on Tuesday June 11, 2013 | Permalink
  4. Richard Vav
    Administrator

    You're welcome, I am glad it worked for you.

    Posted 10 years ago on Tuesday June 11, 2013 | Permalink

This topic has been resolved and has been closed to new replies.