Posted By

ishottheserif on 12/15/09


Tagged

css clearfix


Versions (?)

New Clearfix


 / Published in: CSS
 

URL: http://perishablepress.com/press/2009/12/06/new-clearfix-hack/

  1. /* new clearfix */
  2. .clearfix:after {
  3. visibility: hidden;
  4. display: block;
  5. font-size: 0;
  6. content: " ";
  7. clear: both;
  8. height: 0;
  9. }
  10. * html .clearfix { zoom: 1; } /* IE6 */
  11. *:first-child+html .clearfix { zoom: 1; } /* IE7 */

Report this snippet  

You need to login to post a comment.