How can I change the top/bottom margins between fields on a form? | Community
Skip to main content
Jack_Wildt
Level 2
December 21, 2017
Question

How can I change the top/bottom margins between fields on a form?

  • December 21, 2017
  • 2 replies
  • 3221 views

I am working on some landing page improvements, and I cannot for the life of me figure out how to change the amount of vertical margin between the fields in my form.

My test landing page is here

Any help would be much appreciated!

2 replies

Level 6
December 21, 2017

I think the .mktoOffset  CSS my be the culprit.  You should be able to modify the form's custom CSS..

Something like this should work (by default it looked to be 1.2em, so this would cut the space in 1/2)

.mktoOffset {

    float: left;

    height: 0.6em;

}

If it doesn't seem to take the change you can try    height:0.6em!important;   but don't think you you would need that in this case.

hope it helps!

Gerard_Donnell4
Level 9
December 21, 2017

Its from an inherited box sizing:

Here is a css tricks link that explains it: https://css-tricks.com/inheriting-box-sizing-probably-slightly-better-best-practice/

September 6, 2018

which class inherited that property? I tried the following in custom form css: .mktoForm{        box-sizing:inherit; } and it didn't work.

SanfordWhiteman
Level 10
September 7, 2018

Are you working on the same page as the OP from 2017? If not, you should open a new thread as other pages will have their own issues. What Gerard highlighted is specific to that page, which had/has external (non-Marketo) styles making the task harder.