What are the various clearing techniques and which is appropriate for what context?
What are the various clearing techniques and which is appropriate for what context?
Share
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Aviance School is one of the largest web solutions platform in India for developers to learn and share their programming knowledge and build their careers.
Empty Div Method:
<div style=”clear:both;”></div>
Overflow Method:
setting auto or hidden overflow property on parent will expand it to contain the floats.
The Psuedo Method:
uses the parent’s :after to add the clear: both property
.clearfix:after {
content: "";
visibility: hidden;
display: block;
height: 0;
clear: both;
}