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 trialmatthewroller
2,159 PointsPadding Question
Hello, I am trying to create a padding of top and bottom 15px, and left to right 0px, and when I type in the code.. it gives me an error.. last question of the quiz :\ http://treehouse.offwallattic.com/th-1.JPG
6 Answers
Tom Mertz
15,254 PointsYour link didn't send me anywhere.
But first make sure you are selecting the anchor element (a) inside the nav element (nav).
Then make sure you also set the font weight to 800.
Finally, if you need to set a padding where the top and bottom share a value and the left and right share a value you can use the short hand:
padding: (top and bottom value) (left and right value);
For example, if I wanted a top and bottom of 0 and left and right of 5px it would be
padding: 0 5px;
Don't forget your semi colons!
Good luck.
banu babanu
8,152 Pointsnav a {
font-weight:800;
padding:15px 10px;
}
Ken Alger
Treehouse TeacherHave you tried using the shorthand for the padding? That might be what the challenge is wanting.
nav a {
font-weight: 800;
padding: 15px 10px;
}
sarup
3,352 PointsThe question specifies LINKS. Which means you have to target the anchor tag! :)
matthewroller
2,159 PointsI think that's where I messed up, I didn't use short hand.. thanks guys :)
Tom Mertz
15,254 PointsNo problem man.
Good luck!
matthewroller
2,159 PointsHey guys, here is a link to my syntax.. it doesn't seem to be working... http://treehouse.offwallattic.com/tech-support.JPG
sarup
3,352 PointsMatthew, like I said, the questions says you have to select the LINKS. Which means the code should go under the nav a selector which will select the links not nav li.