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

CSS How to Make a Website Styling Web Pages and Navigation Create a Horizontal List of Links

matthewroller
matthewroller
2,159 Points

How do I select the nav link and add font weight of 800, padding of 15 top bottom, 10 left to right.

How do I set this code? I thought it was like this..

nav li { font-weight: 800; padding: 15px, 10px; }

5 Answers

David Omar
David Omar
5,676 Points

You don't separate the values with commas just a space

nav li { font-weight: 800; padding: 15px 10px; }
dylan goddard
dylan goddard
12,752 Points

Try replacing 'li' with 'a' in your selector. 'li' selects list items and 'a' selects links.

Abhijeet Das
PLUS
Abhijeet Das
Courses Plus Student 3,158 Points

I hope it will works nav a { font-weight:800; padding:15px 10px; }

Here's what it would look like with both David and Dylan's answers:

nav li a { font-weight: 800; padding: 15px 10px; }