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 trialJosh Jones
2,894 PointsThere 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
Erik Nuber
20,629 PointsCould 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.
Josh Jones
2,894 PointsHere's what I have currently.
PAGE: ABOUT
***********************************/
.profile-photo {
clear: both;
display: block;
max-width: 150px;
margin: 0 auto 30px;
border-radius: 100%;
}```
Josh Jones
2,894 PointsI 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
Josh Jones
2,894 PointsJust got it fixed. Added padding: 5%; and it worked great!
Erik Nuber
20,629 Pointsthat's great was just looking at your code. glad you figured it out.
Erik Nuber
20,629 PointsThe 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.