Recently, I crafted this basic HTML:
Within this code are 2 SPAN elements.
I intended for one to sit beneath the other by clearing the float.
The bbb
element is styled with float:left
.
To handle the layout on the aaa
element, I utilized Facebook's "clearfix" CSS technique:
.clearfix:before { content: ""; display: table; }
.clearfix:after { content: ".";
display: block;
height: 0;
clear: both;
visibility: hidden;}
.clearfix { zoom: 1; }
This approach is proven effective (similar to how Facebook does it) and is elaborated upon in a resource here.
Although it functions properly in FireFox (refer to the image above), Google Chrome (version 24) presents a different outcome.
What element have I overlooked?