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.

Can I change the input field box size for individual fields?

  1. Jamisoloman
    Member

    Hi Guys,

    Today is my first day of using Gravity Forms and I'm absolutely loving it already!

    I am looking to create a survey and would like to know if it's possible (if so how) to change the input field box size for individual fields?

    My survey is the same as this one: http://teresagambaro.com/out-about-in-brisbane/surveys-and-petitions/general-survey/

    Thanks

    Jami

    Posted 11 years ago on Tuesday April 5, 2011 | Permalink
  2. Hi Jami.

    Yes, you can target individual fields with CSS

    example: standard text field (input) – applies just to specific text field (based on the unique parent element ID – replace “XX_X” with your actual element ID)

    [css]
    body .gform_wrapper .gform_body .gform_fields #field_XX_X.gfield input[type=text] {width:100px}

    There is also a small, medium and large setting in the form editor that you can apply to each field without having to add any CSS rules.

    Here's the CSS targeting guide for future reference as well. There are lots of samples that you might like to check out.

    http://www.gravityhelp.com/documentation/page/CSS_Targeting_Samples

    Posted 11 years ago on Tuesday April 5, 2011 | Permalink
  3. travin
    Member

    Please excuse my ignorance but how exactly do I find my item's element id? Say for instance I am trying to do the same think Jami wants to on a single line text field with the form id of 3. The text field is the fourth field down from the top.

    Thanks again.

    Posted 11 years ago on Thursday April 21, 2011 | Permalink
  4. You would view your page source, locate the field that you need and then you'll see the id displayed in the markup.

    screenshot: http://grab.by/9VZ4

    This is a lot easier to do with the built in development tools into the Chrome or Safari browsers. You can right-click on the input and then select "inspect element" ( Chrome screenshot: http://grab.by/9VZi ) and it will locate that for you in the markup. I personally use the Firebug plugin for Firefox. It works very similar to the others, but I think it's superior in many ways.

    Posted 11 years ago on Thursday April 21, 2011 | Permalink