Center Checkbox on Form | Community
Skip to main content
November 2, 2015
Solved

Center Checkbox on Form

  • November 2, 2015
  • 1 reply
  • 6537 views

Hi,

We are creating a form with the label positions on the left and the field on the right. For the checkboxes, we want to override this styling and have the field (checkbox) below the label and centered for our desktop and mobile verison. Our checkbox currently is left aligned. Does anyone have a solution for this?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Grégoire_Miche2

Hi Amanda,

I gave it a look and in fact, I understand where your problem comes from : there is no class, hook nor id that enables to format the label for checkboxes separately form the other labels in the form.

It will likely require some JS scripting to dynamically add a class or id to this "mktoFormCol" element so that you can apply some specific CSS to the label and the checkbox.

I am not that good at scripting

@Sanford Whiteman​ may know better

-Greg

1 reply

Grégoire_Miche2
New Participant
November 2, 2015

HI Amanda,

This can be done using CSS styling either on the form, or in the LP template.

-Greg

November 2, 2015

Hi,

Yes, I know this. I'm not sure of the CSS code though. Can you provide this code?

Grégoire_Miche2
Grégoire_Miche2Accepted solution
New Participant
November 2, 2015

Hi Amanda,

I gave it a look and in fact, I understand where your problem comes from : there is no class, hook nor id that enables to format the label for checkboxes separately form the other labels in the form.

It will likely require some JS scripting to dynamically add a class or id to this "mktoFormCol" element so that you can apply some specific CSS to the label and the checkbox.

I am not that good at scripting

@Sanford Whiteman​ may know better

-Greg