2 Replies Latest reply on Dec 18, 2016 9:59 PM by Sanford Whiteman

    Forms 2.0 CSS for hidden field

    Alexis Devonish

      Hello!

      I'm new to the CSS world and have a challenge where I need the text of a hidden checkbox field (displayed by visibility rules) to align better with the rest of the form. In the image below, the text is off and while I have tried adjusting the label/field width, it doesn't work. In terms of CSS for the form, is there a recommended code to adjust only that field so that it's a bit more centered and the checkbox is inline with the rest of the text?

       

        • Re: Forms 2.0 CSS for hidden field
          Sanford Whiteman

          URL, please. Can't troubleshoot a screenshot.

           

          Also, just to be precise: it can't be Hidden (that's an actual, mutually exclusive field type) if it is governed by Visibility Rules. "Conditionally displayed," maybe....

          • Re: Forms 2.0 CSS for hidden field
            Sanford Whiteman

            Don't know what alignment you're going for ("a bit more centered" isn't enough), but you can start restyling your particular form with this:

             

            .mktoFormRow .mktoHasWidth[for="Unsubscribed"] {
               width: 250px !important;
               float: right;
            }
            .mktoFormRow .mktoHasWidth[for="Unsubscribed"] ~ .mktoCheckboxList {
               margin-top: 6px;
            }
            .mktoFormRow .mktoHasWidth[for="Unsubscribed"] ~ .mktoCheckboxList input {
               margin-left: 12px;
            }
            
            1 of 1 people found this helpful