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 trialAlonso Sainz
2,615 PointsWhen I add color to the header background it only uses the color I applied to all the document background
I added a grey color to all the document bakground (*{background-color:#e6e6e6;}) but after that when I apply a darker grey to the header (header{bakground-color:#b3b3b3 }) it doesnt apply it just uses the overall background color. How can I change it with out afecting the overall color?>
4 Answers
Birte Müller
Front End Web Development Techdegree Graduate 16,026 PointsIs this an exact copy of your code? Because here the background-color for your header is lacking a c and the semicolon is missing. After correcting the typo it should work. header{background-color:#b3b3b3; }
Jake Cooper
Courses Plus Student 56,854 PointsIf you are defining the header before the / above the *{ ... } selector you may be overwriting it. Make sure you are defining header{ } below / after the * { } definition.
Otherwise like Birte said above check your spelling for you properties within header { ... } definition.
Alonso Sainz
2,615 PointsSorry it is a typo. And I did define *{...} before the header
Alonso Sainz
2,615 PointsA friend helped me and I aplied the background color to the body insted of the *. Thanks for helping me a bit
Oscar Vargas Sanchez
1,382 PointsOscar Vargas Sanchez
1,382 PointsTry adding a class or an id to the header that would make it easier adding styles to your header.