Universal Clearfix Hack

I’ve been using this little piece of code all over the place for months now. Tracked down the original use here: /* CLEARFIX !! — slightly enhanced, universal clearfix hack */ .clearfix:after { visibility:hidden; display:block; font-size:0; content:” “; clear:both; height:0; } .clearfix { display:inline-block; } /* start commented backslash hack \*/ * html .clearfix { [...]

Detecting IE6 in jQuery

if ($.browser.msie && parseInt($.browser.version)< 7) { //code goes here }