Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

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

Pablo Smith
Pablo Smith
5,632 Points

I keep getting a CSS error on "Styling Web Pages and Navigation", Challenge task 4 of 4?

I keep getting an error that the top padding should be 15px on list elements nested in the nav, this is my css:

nav li { display: inline-block; font-weight: 800; padding: 15px 10px 15px 10px; }

I've also tried:

nav li { display: inline-block; font-weight: 800; padding: 15px 10px; }

2 Answers

Pablo Smith
Pablo Smith
5,632 Points

The instructions asked to put in to the nav links, I thought that meant nav li {} but it meant nav li a {} :)

idan ben yair
idan ben yair
10,288 Points

Hi try:

nav li { display: inline-block; font-weight: 800; padding-top: 15px; }
Pablo Smith
Pablo Smith
5,632 Points

Wasn't the answer, but thanks for helping!