Skip to main content
How to Display the Email Opt-in Module's Fields Inline

Learn how to display the Email Opt-in Module's fields inline in Divi for a sleek and streamlined form design that boosts sign-ups.

Updated over 3 months ago

Enhancing the layout of your email opt-in forms can improve their visual appeal and user experience. By displaying the Email Opt-in Module's fields inline, you can create a sleek design that encourages more sign-ups.

This article will guide you through the steps to customize the Email Opt-in Module in Divi so that its fields are displayed inline, making your forms more attractive and effective.

Out of the box, the Email Opt-in module layout is as shown in the image below:

Email Opt-in module

Customize the Email Opt-in module to display the fields inline (side-by-side)

  1. Open the Email Opt-in module settings and delete the Title text and the Body Text

  2. Go to Advanced Tab → Custom CSS → Free Form CSS

  3. Copy/paste the following CSS snippet:

@media (min-width: 768px) {
selector .et_pb_newsletter_fields {
display: grid;
grid-template-columns: repeat(4, 1fr);
grid-gap: 20px;
}

selector .et_pb_newsletter_form p.et_pb_newsletter_field {
padding-bottom: 0;
}
}

The above CSS Code uses CSS Grid.

Email Optin module Free Form CSS

The result can be seen in the screenshot below:

Email Opt-in Module's Fields Inline

Note: Adding the above CSS snippet to the Email Opt-in module → Advanced Tab → Custom CSS → Free Form CSS might mark it as having syntax errors.

Please ignore those since they are false positives. They appear as errors because the WordPress syntax checker has to be updated to recognize valid CSS units and properties.

Did this answer your question?