Clear floats with pseudo class


/ Published in: CSS
Save to your folder(s)



Copy this code and paste it in your HTML
  1. .group:before,
  2. .group:after {
  3. content:"";
  4. display:table;
  5. }
  6. .group:after {
  7. clear:both;
  8. }
  9. .group {
  10. zoom:1; /* For IE 6/7 (trigger hasLayout) */
  11. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.