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

HTML How to Make a Website Styling Web Pages and Navigation Build Navigation with Unordered Lists

Joseph Lu
Joseph Lu
698 Points

can't remove the spacing at the very top when setting margin to 0 0 30px 0

i know there's a another post about this and i tried everything in that post and nothing has worked. however, when i use google inspect and remove float: left. everything will work fine as in the video. so can someone explain why it worked this way and not like it in the video?

3 Answers

You can see you have a fault in your html because there are red lines. Try to find out what before reading further. . . . . . . . . . Two opening ul tags instead of one.

Joseph Lu
Joseph Lu
698 Points

Thx, i got it

You need to insert a padding-top: 1px;

For more information you can look at the course: CSS layout

The problem is collapsing I found out.

Joseph Lu
Joseph Lu
698 Points

where do i insert padding-top: 1px? i try to put it in the header but it didn't work.

I can't see the code so it's a bit difficult for me to;P