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
Tyler Keiser
861 Pointscode challenge Give the header element a class attribute. Then, set the class value to main-header.
Hi im stuck on this code challenge and i swear i got it right. i just put class="main-header" both with and without the peroid at the end of the sentence inside the header tag. if you could help me out that would be great.
heres a link https://teamtreehouse.com/library/css-basics-2/basic-selectors/id-and-class-selectors#
7 Answers
Jonathan Grieve
Treehouse Moderator 91,254 PointsIt sounds like you've got all the bases covered. A class on the < header > element.
<header class="main-header"></header>
If you put those in for the first part of the challenge it should work. :-)
Hope this will help. :)
sjbrown0324
13,995 Points<header class="main-header">
grahamfleming
6,405 PointsBut treehouse is this not wrong?
In the code that is already provided there is already a </header> in the HTML
Using the code provided above will give you the right answer, but will close the header too soon and not actually put the desired content into the header!?!?
<header class="main-header"></header>
<span>Journey through the Sierra Nevada Mountains</span>
<h1>Lake Tahoe, California</h1>
</header>
MUZ140812 Phumza Malumo
6,496 PointsI am also stuck on this! I've watched the video about 3 times over. No luck. Has this been resolved?
sjbrown0324
13,995 PointsHave you tried the answer above. It should work.
<header class="main-header"></header>
alexa swain
1,564 PointsTHANK YOUUUUUU!!!!!!!!!!!!!!!!!!
Dane Elder
7,569 PointsIt sure has. the first angle bracket starts the sentence. We put header class, then an equal sign, then the quote, then main-header. then we close with the other angle bracket. It's done right after the word header and before the word span. make a line space and just put it in. That should keep your code clean.I hope this helps, even if the author's post is old.
Tavonga Lewis
2,891 Pointsweeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeel dooooooooooooooooooooooooooooooooneeee!
Kullen Carter
1,107 Points<header class="main-header"></header>
Janeth Blevins
1,443 Points<div="main-heading">
.main-heading { font-size: 72px; }