Cyber Monday Sale Ends in

0Days

0Hours

0Minutes

0Seconds

Buy Lifetime Membership
×

Search Events Calendar Child Theme for Divi Documentation

Search for answers or browse our knowledge base.

< All Topics
Print

How to change background color of the menu’s last child item?

To change the background color of the last menu item, you can add the following CSS code to your WordPress theme:

  1. Navigate to Appearance > Customize in your WordPress Dashboard.
  2. Select Additional CSS.
  3. Paste the CSS code into the provided text area.
  4. Click Publish to save your changes.
.et_header_style_left #et-top-navigation .header-registration-btn a {
    border-color:    #FF0000 !important;
    background-color:#FF0000 !important;
}

Note: In the above code you can change the color according to your preferences.

Output:

To change the color on the hover state add the below CSS

.et_header_style_left #et-top-navigation .header-registration-btn a:hover {
    border-color:     #000 !important;
    background-color: #000 !important;
}
Was this article helpful?
0.5 out of 5 stars

1 rating

5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 100%
5
Please Share Your Feedback
How Can We Improve This Article?
Cyber Monday Popup