WordPress.org

Support

Support » Themes and Templates » Changing CSS headers

Changing CSS headers

  • Beth

    @pedalkraft

    I know this should be simple, but I can’t seem to change the colour of the h2 and h3 text on my site. It’s not live so I can’t share a link, but it’s fairly generic, I would just like to change the headers to purple rather than black. It;s a straightforward thing I’ve done plenty of times before, but it’s just not coming through!

    I’ve tried this in the CSS file and also pasted it into the Custom CSS box in the Theme Options: (#600b75 is the purple).

    h2, h3, {
    color: #600b75;
    margin-bottom: 18px;
    }

    h1, h4, h5, h6 {
    color: #000;
    margin-bottom: 18px;
    }

    h1 { font-weight: normal; font-size: 26px; line-height: 36px; }
    h2 { font-weight: normal; font-size: 20px; line-height: 30px; color: #600b75; }
    h3 { font-weight: normal; font-size: 16px; line-height: 24px; color: #600b75; }
    h4 { font-weight: normal; font-size: 12px; line-height: 18px; }

    …any suggestions gratefully received!

    Thanks 🙂

    Beth

Viewing 1 replies (of 1 total)
  • paulwpxp

    @paulwp

    Font hero

    Inspect the element and see what HTML structure it is in and what class associates with it.

    Suppose you have this in the HTML

    <header>
    	<h1 class="entry-title"><a href="">Hello world</a></h1>
    </header>

    and this already in the CSS

    a { color: red; }

    when you add this after it, it wouldn’t work

    h1 { color: black; }
Viewing 1 replies (of 1 total)
  • The topic ‘Changing CSS headers’ is closed to new replies.