To align checkboxes horizontally in WPMUDEV Forminator using a custom class, you’ll need to add some custom CSS. Here’s a step-by-step guide:
1. Add a Custom Class to Your Form:
- Edit your form in Forminator.
- In the “Advanced” tab of your form field settings, add a custom class name to the checkboxes (e.g., horizontal-checkboxes).
2. Add Custom CSS:
- Go to your WordPress dashboard.
- Navigate to Appearance > Customize > Additional CSS.
3. Enter the Custom CSS:
.horizontal-checkboxes .forminator-checkbox {
display: inline-flex;
align-items: center; /* Vertically aligns the checkbox and label */
margin-right: 15px; /* Adjust spacing as needed */
}
.horizontal-checkboxes input[type="checkbox"] {
margin-right: 5px; /* Space between checkbox and label */
}
.horizontal-checkboxes label {
margin: 0; /* Remove any default margin from labels */
}
4. Save Changes:
- Click the
Publish
button to apply the changes.
This CSS will make the checkboxes align horizontally and adjust the spacing between them. If you need further customization, you can tweak the margin-right
values or add additional styles as needed.
Share Your Two Cents