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 trialLuciano Heleno da Rosa
4,385 PointsProblem with the ul.nav li
I am trying to set the widths of all the elements of the SmellLikeBakin page, but I can't find the right percentage to ul.nav li margin-right
ul.nav li {
float: left;
margin-right: 40px;/*40px*/
}
For every number that I tried it breaks the layout, and displays all the <li> elemens one below the other.
2 Answers
John W
21,558 Pointstry adding this in front
ul.nav { display: block; }
John W
21,558 PointsSomewhere you may have set ul or .nav to display:inline-block, so I'm resetting it.
Luciano Heleno da Rosa
4,385 PointsLuciano Heleno da Rosa
4,385 PointsYeah it makes sense in solving the problem, but I still don't understand why it behave like this. But Thank you anyway :)