PDA

View Full Version : Settings DIVs to be relative height?



194673
Apr 10th, 2007, 07:16 AM
Alright, well I'm trying to get these two divs to be the same height whenever one expands (in height). What I thought would work didn't... What I did was try creating a container with an undefined height, then setting two divs floating next to each other in that container with a height of 100%. Now I just have the two divs set up with a min-height - but that won't do what I want it to do, since once one of the heights is exceeded, the other won't expand. As far as min-height's go, which browsers is this attribute compatible in? I have only tried FF and IE7.

On a side note, does anybody know how to get a text size to stay absolute (i.e. always 12px). Yes, I know, horrible in terms of accessibility, but I want to do it only for a section title (and it's over a background image, so the font has to fit in that image)

Excavator
Apr 10th, 2007, 07:29 AM
Google "faux columns" to get equal column height. Here's an example or two:
3column (http://www.nopeople.com/CSS/full-height-3column/)
2column (http://www.nopeople.com/CSS/equal_length_columns/)

Whenever I have a title or menu that won't survive a text-size change in the end users browser I just use an image.

194673
Apr 10th, 2007, 07:46 AM
Thanks, I'll try that tomorrow. I've got school in 4 hours, and I'm kind of tired. BTW, as for the images suggestion... I don't want to make 20+ images, so I wanted to just have some dynamic text, since my content is dynamic too (deciding on using either previously known PHP or learning AJAX).

_Aerospace_Eng_
Apr 10th, 2007, 01:07 PM
Then don't set heights on areas that allow text resizing. Ironically in IE if the font-size is set in px or pt it can't be resized.