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
Adama Sy
7,076 PointsSelect the copyright using an ID selector
I did it but i still have error, here is my code in the style sheet:
copyright {
border-top: 8px; solid #2A0400; }
the question asked is: Select the copyright using an ID selector. Give it a solid top border that is 8 pixels thick and has a color of #2A0400.
but I get this always:Bummer! Remember, to select an ID, use the '#' character followed by the ID of the element you want to select.
what is wrong in what I did?
3 Answers
Dave Thomson
3,157 PointsThe error message is a little bit of a red herring, the problem isn't with how you have selected the element ID but with the style declarations.
The parser isn't seeing the values for border type and colour because there is an extra semicolon terminating the declaration early.
#copyright {
border-top: 8px solid #2A0400;
}
Jenny Swift
21,999 Pointstry this:
copyright {
border-top: 8px solid #2A0400;
}
I think you were having trouble because you didn't put the # in front of copyright to make it an ID selector, and also because of the semi-colon after 8px.
Jenny Swift
21,999 PointsOops. I typed in a # before copyright and it didn't show. How about this then?
#copyright {
border-top: 8px solid #2A0400;
}
Also it might be a good idea if when you include your code if you do the ``` marks like it says in the markdown cheatsheet.
Adama Sy
7,076 PointsAdama Sy
7,076 PointsThank you