Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Auto height not working Reply To: Auto height not working

#183609
PrincipOfCode
Participant

Hi united9,
You can use display property in css, change to “display: table;” in the container of both divs, and for both divs declare them as “display: table-cell;”, so you also don’t need to use “float: left” or right ..
instead you can use “padding” with “box-sizing: border-box;” inside the divs and the container.
In this way you can leave “height: auto;” inside your divs … it will stretch the height of your divs to the height of the bigger of them ..