Normally, when you float divs (columns) they only expand height-wise as tall as their contents. Thus, if you have a background color on the divs, some of the columns might not stretch all the way down: e.g. you end up with scattered, messy looking columns.
Common fixes include
adding a cleared div below them, but that isn't semantic
setting the columns' container div to overflow:hidden
I haven't looked at it, but the jQuery solution might be more cross-browser compatible.
13 comments
Always appreciate new css and jquery tricks; but what is the purpose of the equal height columns (number 1 on the list)?
It says in the article that getting columns to be at equal heights is a problem for designers. How is that true?
you must be new to this...
I am sort of, but mostly I haven't done anything involving matching columns next to each other yet..
Normally, when you float divs (columns) they only expand height-wise as tall as their contents. Thus, if you have a background color on the divs, some of the columns might not stretch all the way down: e.g. you end up with scattered, messy looking columns.
Common fixes include
adding a cleared div below them, but that isn't semantic
setting the columns' container div to overflow:hidden
I haven't looked at it, but the jQuery solution might be more cross-browser compatible.
Can't you just set the height? Or does that only work with absolute positioning?
Deleted before we saved it.
You are thanking yourself?
And he edited it. Maybe it was 'Thank me!' at first but he thought that was a little too narcissistic.