Return to the article: What is the difference between the closed floating and the cleared floating in those years. main: Sorry. In modern browsers, I cannot lift warp (float: left ). side: I also float (float: left ). footer: I set clear: Both
Clear floating Although the location is correct, the height of warp remains unchanged, which is a bit uncomfortable. main: warp is closed and floating, so footer does not need to clear the floating (float: left ). side: I also float (float: left ). footer: This warp outbreak passed. clearfix already
Closed floating (1) Add additional labels. main {float: Left ;}. side {float: Right ;}. footer2) use the BR tag and its own HTML attributes. main {float: Left ;}. side {float: Right ;}
. Footer3) parent element overflow: hidden. main {float: Left ;}. side {float: Right ;}. footer6) set the parent element to display: Table. main {float: Left ;}. side {float: Right ;}. footer
From: http://www.iyunlu.com/demo/enclosing-float-and-clearing-float/index.html