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 Adding Pages to a Website Style New Pages

There is no margin between the header and the image after following along.

I've been following along with Nick, and even tried the code from the teacher's notes. My image is too close to the bottom of the header, and there is no space. What am I doing wrong here?

5 Answers

Could you post your code? Most likely you just need to add some padding or margin

img {
    margin-top: 15px;
}

in the video he does this using

.portfolio-photo {
    margin: 0 auto 30px; 
}

which makes the margin top 0 left/right auto and bottom 30px as his photo is over the text.

Here's what I have currently.

PAGE: ABOUT
***********************************/

.profile-photo {
  clear: both;
  display: block;
  max-width: 150px;
  margin: 0 auto 30px;
  border-radius: 100%;
}```

I still can't figure out what is going on with the no margin. Here's a snapshot of what I'm working with: http://w.trhou.se/dy58la80vo

Just got it fixed. Added padding: 5%; and it worked great!

that's great was just looking at your code. glad you figured it out.

The only difference I see in your code is the clear: both; which should not be effecting the margin on the bottom.

The only other thing it might be is how you coded the h3 tag.