Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS How to Make a Website Customizing Colors and Fonts Pick Fonts and Set Relative Units

Rich Braymiller
Rich Braymiller
7,119 Points

Why isn't my header green?

Okay I do not get why my header isn't green....something is not right...and I am unsure what....

<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>Rich Braymiller | Designer</title> <link rel="stylesheet" href="css/normalize.css"> <link href='http://fonts.googleapis.com/css?family=Changa+One|Open+Sans' rel='stylesheet' type='text/css'> <link rel="stylesheet" href="css/main.css"> </head> <body> <header> <a href="index.html" id="logo"> <h1>Rich Braymiller</h1> <h2>Designer</h2>
</a> <Nav> <ul> <li><a href"index.html" class="selected">Portfolio</a></li> <li><a href="about.html">About</a></li> <li><a href="contact">Contact</a></li> </ul> </Nav>
</header> <div id-"wrapper"> <section> <ul id="gallery"> <li> <a href="img/numbers-01.jpg"> <img src="img/numbers-01.jpg" alt=""> <p>Experimentation with color and texture.</p> </a> </li> <li> <a href="img/numbers-02.jpg"> <img src="img/numbers-02.jpg"> alt""> <p>Playing with blending modes in Photoshop.</p> </a> </li> <li> <a href="img/numbers-06.jpg"> <img src="img/numbers-06.jpg"> alt""> <p>Trying to create an 80's style of glows.</p> </a> </li>

    </ul>


  </section>

</div>

</body>

</html>

/****************************************** General *******************************************/

/* site body */ body { background-color: #fff; color: #999; }

body { font-family: 'open sans', sans-serif; }

wrapper {

max-width: 930px; margin: 0 auto; padding: 0 5%; }

a { text-decoration: none; }

/****************************************** Heading *******************************************/

logo {

text-align:center; margin: 0; }

/* green header*/

/****************************************** Colors *******************************************/

header { color: #6ab47b; border-color: #599a68; }

/* Nav Background on mobile devices */ nav { background: #599a68; }

/* logo text */

h1, h2 { color:#fff; }

/* links */ a { color:#6ab47b; }

/* nav link / nav a, nav a:visited { color: fff; } / selected nav link*/ nav a.selected, nav a:hover { color: #32673f; }

4 Answers

Courtland Santos
Courtland Santos
8,547 Points

You need to change "border-color" to "background-color." If you still want to have a border color, then try using the short-code like the following:

header { border : 1px solid #599a68; }

I think you added a border-color for your header instead of a background-color.

rydavim
rydavim
18,814 Points

The color attribute refers to the text color, and the border-color will only effect the border. Currently I don't see a background color for the header in your CSS.

There are a couple other minor typos that might cause you issues further along:

You want you nav tag to be lowercase.

Your wrapper tag has a dash in there that shouldn't be. Make sure you're always using an ( = ) when assigning IDs and classes.

On your second and third images, your alt text attribute is outside of the img tag. You have an extra ( > ).

In your CSS file, you'll need to use #wrapper to select the wrapper ID tag. It's missing the hash ( # ) at the moment.

nice. i'm impressed :)

Rich Braymiller
Rich Braymiller
7,119 Points

thanks so much that did it! Making progress, slowly...