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 trialVarayut Lerdkanlayanawat
Courses Plus Student 5,439 PointsWhy we use overflow:hidden/display: table to clear float?
After watching this video, I have two questions:
1. Why overflow:hidden could be used to clear the float?
In the previous video, it was used to hide all the overflow text. Could you explain a little bit how did the overflow:hidden do the trick in this case?
2. Why display:table should be used to clear the float?
Can we use other display; block, inline-block instead of table?
1 Answer
Rich Bagley
25,869 PointsHi Varayut,
This probably explains it better than I can:
http://css-tricks.com/all-about-floats/ under the heading Techniques for Clearing Floats
Hope that clears it up.
-Rich