PDA

View Full Version : DIVs won't accept vertical-align?


The Ace
05-10-2006, 04:26 AM
Why when I want to make a DIV's text to be v-aligned in the middle\bottom of the div when I have a specific height for the DIV, the text stays stuck at the top of the DIV?

currently i'm using padding-top\bottom to create a virtual v-align: middle; for the DIVs, but I'm sure that I'm missing something here...

Thanks again

CrAzY_J
05-10-2006, 04:44 AM
This is not HTML, meaning no abrreviations.


vertical-align:middle;

Kravvitz
05-10-2006, 05:31 AM
Read this. (http://www.dynamicsitesolutions.com/css/vertically_centering_with_line-height/)

ronaldb66
05-10-2006, 08:03 AM
vertical-align only applies to inline elements and content, and table cells, so not block level elements like divs.