Equal Height Columns (DIVs)


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

There is also a jQuery plugin


Copy this code and paste it in your HTML
  1. function equalHeight(group) {
  2. tallest = 0;
  3. group.each(function() {
  4. thisHeight = $(this).height();
  5. if(thisHeight > tallest) {
  6. tallest = thisHeight;
  7. }
  8. });
  9. group.height(tallest);
  10. }
  11.  
  12. $(document).ready(function() {
  13. equalHeight($("#left,#right,#content"));
  14. });

URL: http://www.cssnewbie.com/equal-height-columns-with-jquery/

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.