Subscribe On YouTube

Join other subscribers and enjoy other Divi video tutorials!

How To Add Focus Input Field Borders To The Divi Contact Form

Nelson Miller Profile Orange
In this tutorial I will show you how to make highlighted focus input field borders in the Divi Contact Form module.

▶️ Please watch the video above to get all the exciting details! 👆

FYI: You can do this with a setting directly in the Divi Contact Form module with our popular Divi Contact Form Helper plugin! Take a look, it is so easy!

Divi Contact Form Helper adds over 115 new features.

1. Add A Custom CSS Class To The Divi Contact Form

The first step in the tutorial is to add a custom CSS class to the Contact Form module. This is used to target the correct module with the code in order to only make this affect only a specific module. 

To add the custom class, open the module settings and go to the Advanced tab. Go to the CSS IDs & Classes toggle. Place the class “pa-contact-form-focus-borders” in the CSS Class input field of the Contact Form module.

add the CSS class to the Divi Contact form to add focus input field borders

2. Add The Custom CSS Code Snippet

The second step is to add the custom CSS code to your website. This step is also very easy, and we are doing the work with only a few lines of CSS.

Where To Paste The CSS Code

1. Divi Assistant
If you are using our Divi Assistant plugin, simply paste the code in the CSS tab in the custom code window in the Divi Visual Builder.

2. Child Theme
If you are using a child theme, paste this code into the style.css file. If you don't have a child theme, you can generate a child theme directly on your site or download our free child theme.

3. Divi Theme Options Integration
Otherwise, paste this code in your Divi>Theme Options>Custom CSS code box.

If you need help understanding where to paste the code, please check out our complete guide about where to add custom code In Divi.

/*add focus input field borders to the Divi Contact Form module*/
.pa-contact-form-focus-borders input:focus,
.pa-contact-form-focus-borders textarea:focus {
	border: 2px solid #00d263;
}

After adding and saving the code, your form fields would look like this when you click to type:

focus input border styling for the Divi contact form

The code is very simple. It targets the custom class added to the module and uses the :focus pseudo class. The focus state is triggered when a user clicks within the field element. When that happens, the CSS for the border is applied.

You can customize the thickness and color according to your own preference.

Do It With A Setting!

Make life easier and use the Divi Contact Form Helper plugin instead, the ultimate Divi Contact Form upgrade with awesome features and settings!

Divi Contact Form Helper adds over 115 new features.

The Divi Contact Form Helper plugin has design settings to quickly add the focus input borders. Using the plugin can save you loads of time and add lots of additional functionality. Be sure to check out all the other amazing features!

input field focus border settings in the Divi Contact Form Helper plugin

Subscribe For More Things Like This!

At the start of each month, we send out a recap newsletter from the month before with family news, Divi news, our latest tutorials, and product news. Occasionally, if the news is too exciting to wait, we will send out another email separate from the monthly newsletter. That’s what you get when you subscribe, and of course you can unsubscribe if you are no longer interested!

Blog Post Optin
Divi Logo (2)

Shop Our Divi Products

Plugins • Courses • Templates

Visit The Shop

Featured Products

Asset 4

New! Trail Guides

Follow a series of blog posts carefully arranged around a specific topic or goal! Keep track of your progress by marking posts completed, just like a free course!

View Trial Guides

Divi Trail Committee Membership badge with map design

Join The Trail Committee!

Show support for our ongoing work creating community resources at Pee-Aye Creative and enjoy exclusive member perks in return.

Learn More

Divi Tutorials On YouTube

Our videos have views! Join subscribers and enjoy over video tutorials!

Visit Our Channel

Leave A Response!

By commenting you agree to our Blog & YouTube Comments Policy

2 Comments

Comments By Others

  1. Peter

    Excellent thank you again. Nice and easy as always. A nice little touch, put it straight on and using it.

    Reply

Submit a Comment

Your email address will not be published. Required fields are marked *

Recent Posts

0

Your Cart