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 trialMichael Hemmins
2,797 PointsCSS: display: block; will not show image
Hi
For some reason I can't get an image to display when I include the following css:
.profile-photo { display: block; max-width: 150px; margin: 0 auto 30px; border-radius: 100%; }
If I delete the 'display: block;' property, the image shows. Any thoughts?
3 Answers
paulbacon
21,926 PointsHi Michael,
This seems to be a browser issue (Firefox) and has popped up before on the forums.
There's a couple of posts here which explains it along with the "fix" in more detail...
https://teamtreehouse.com/forum/display-block-makes-my-image-of-nick-disappear
https://teamtreehouse.com/forum/problem-centering-display-inlineblock
Hope that helps
Paul
Michael Hemmins
2,797 PointsPaul, thanks. I guess life would be far too boring if we didn't have to mess about with incompatible browsers!!!
paulbacon
21,926 PointsAbsolutely, keeps us on our toes! :)