/ Published in: CSS

Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
/** * Clear floats when child elements are contained within the bounds of the selected element. */ .selected_element {overflow: hidden} /** * Clear floats when child elements are positioned outside the bounds of the selected element. */ /** * Only needed for IE6 & IE7 if hasLayout has not been triggered by some other property * @see http://reference.sitepoint.com/css/haslayout */ .selected_element{display:inline-block} /** * For standards compliant browsers (including IE8+) * "\200B" is unicode for ZERO WIDTH SPACE. Neat. */ .selected_element:after{clear:both;content:"\200B";display:block;height:0}
Comments
