Skip to main content
November 9, 2015
Question

How to vertically align label and asterisk in forms

  • November 9, 2015
  • 8 replies
  • 5072 views

If you look at the attached image the the label, asterisk and dropdown are all vertically aligned. This is not true for the input labels.

How can I achieve all 3 elements to be vertically aligned ?

Thanks!

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

8 replies

Stijn_Heijthuij
Level 6
November 9, 2015

Hi Danny,

You can edit the CSS of a form to override the styling given by MKTO. Take a look here; Edit the CSS of a Form Theme - Marketo Docs - Product Docs

Using the added tag !important will override the default styling.

Let me know if you can get that working.

November 9, 2015

Hi Stijn,

Thank you for the quick reply.

I have been adding the custom CSS using the websites stylesheet and have been using !important. If you click on the link below you'll see the form i'm working on and adding the following to the styesheet simply won't work.

.mktoForm .mktoRequiredField label.mktoLabel {

vertical-align: middle !important;

}

Request a Demo

If I could isolate the text label itself maybe I could play with the margins but can't since they are all grouped together.

Any ideas what I can do to have all elements vertically aligned ?

Stijn_Heijthuij
Level 6
November 10, 2015

Hi Danny,

It might be some fiddling around, but have you tried playing with the margin-top aspect?