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 trialJason Rollins
921 PointsAdding copyright ID selector
I believe I have put the correct code for this challenge (Add copyright ID selector with top border) however, it says this is incorrect. And I put a pound sign before the copyright but I don't think that is showing up on here.
'''css
copyright {
border-top: 8px solid #2A0400;
} '''
Dylan Dixon
947 PointsHow does it look good? His problem is clearly in the selector, he put 'copyright' rather than '#copyright'.
4 Answers
Christina Pagano
15,676 PointsFor ids, you have to put the hash (#) symbol in front of the id name in your selector. So it should be #copyright.
Dylan Dixon
947 Pointscopyright , the id will always be called upon in css by a # and the classes will always be called upon by a . .
Example below
#id{
border-top:8px solid #2A0400;
}
/*if you were going to use a class, which you are not, you would use a ., example below*/
.class{
example:example value;
}
Got it?
Jeff Busch
19,287 PointsIf you actually READ Jason's post you would realize that Jason stated "And I put a pound sign before the copyright but I don't think that is showing up on here."
Dylan Dixon
947 PointsOh haha whoops. Yeah guess I missed that.
Christina Pagano
15,676 PointsI also failed at the full read. My apologies Jason.
Dylan Dixon
947 PointsOkay I just tried it out, and I have the same code as you and it worked.
#copyright{
border-top:8px solid #2A0400;
}
this is what you had right? I can't really see the problem, hmm.
Where did you put it in the code?
Dylan Dixon
947 PointsThat posted twice for some reason..
Dylan Dixon
947 PointsOkay I just tried it out, and I have the same code as you and it worked.
#copyright{
border-top:8px solid #2A0400;
}
this is what you had right? I can't really see the problem, hmm.
Where did you put it in the code?
Jeff Busch
19,287 PointsJeff Busch
19,287 PointsHi Jason,
You're code looks good to me. Maybe THIS will help with posting code.
Jeff