Could not find an answer to this searching the forums or the web... Is it possible to expand a <div> element to the size of its contents?
I'm trying to achieve a two-column layout that is not the full page height... there are two columns in the header, and I want them both to be the same size, whichever is larger. I can make both columns fill 100% of the screen by setting the container div height to 100% (a commonly asked question)... but if I only want the div to be as tall as the tallest column's text?
A simple example page is here:
http://home.comcast.net/~sngbrdb/divtest.html
A link to the css in this example:
http://home.comcast.net/~sngbrdb/divtest.css
Ideally, the background in the column on the right would expand to be the same height as the column on the left. But because the containing div doesn't expand to the size of the contained elements, the 100% height on the right column div is meaningless.
Thanks in advance!