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.

CSS Styling for sidebar forms

  1. jochan
    Member

    Hi,

    My website has a main enquiry form and I wish to add a short form on the sidebar, I have to significantly reduce the width of the sidebar form to fit.

    Just to confirm, if I change, say for example, the width of .gform_description, i'll be essentially changing the width of all other gravity forms on the website, which is not what I want to do.

    Or is this going to work?
    #field_1_13 .gform_description {}

    Please point me to the right direction.
    Thanks.

    Posted 9 years ago on Saturday June 19, 2010 | Permalink
  2. You're right. Most of the fields have unique ID's so you can use inheritance to target specific ones like your example.

    It all depends on how specific you need to be. If you want to change all of the descriptions for Form #1, you can start your inheritance from the main form wrapper.

    #gform_wrapper_1 .gfield_description {color: red}

    If you only the property applied to the specific field, then something more specific like this.

    #gform_wrapper_1 #field_1_5 .gfield_description {color:blue}

    Hope that helps. We also put together a visual guide for the CSS that you might find useful.

    http://www.gravityhelp.com/documentation/visual-css-guide/

    Posted 9 years ago on Saturday June 19, 2010 | Permalink