H2 headings a background color

Hello, I have two questions:

  1. how can I give all my H2 headings a background color, see example
    and
  2. how can I give a distance to the text for all my H2 headings?

Many Thanks !

Hello @ratgeber,

Thanks for asking. :slight_smile:

You can add following CSS under X > Theme Options > CSS to make necessary changes in h2 element sitewide:

h2 {
    background-color: #ddd;
    word-spacing: 5px;
}

Thanks.

That with the background worked. Now I still need the solution, as the distance between the title and the underlying text, so the first line can enlarge.

Many Thanks

Hi again,

Try adding the following CSS code in the Theme Options > Global CSS:

h2 {
    margin-bottom: 15px;
}

Let us know how this goes!

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.