CupidDeLocke
10-30-2003, 11:46 PM
how in heavans name do i center my div in a vertical fashion (without tables)?
|
Click to See Complete Forum and Search --> : Vertically align divs CupidDeLocke 10-30-2003, 11:46 PM how in heavans name do i center my div in a vertical fashion (without tables)? spufi 10-31-2003, 12:03 AM CSS: div { vertical-align:middle; } Now, it depends on where you are trying to center it against is where things get quirky. If you want to center it in an area and then as the div grows it stays in the middle, you are set. If you define a specific height for the div you are still good for the most part. You can not however define the height as having a value of some percentage. For some reason it works if there is not Doctype and thus the browser goes into quirks mode, but if the Doctype is there, the percentage height is basically ignored, and yes, this is one of the no-brainer things that needs to be changed. fredmv 10-31-2003, 01:14 AM http://www.wpdfd.com/editorial/wpd0103.htm#toptip webdeveloper.com
Copyright Internet.com Inc., All Rights Reserved. |