View Full Version : Centering Text in CSS.
02-11-2005, 07:47 PM
What's the appropriate way to vertically center a line of text inside a css <div>
I realize that <center></center> doesn't validate.
02-11-2005, 08:10 PM
I believe its: text-align: center;
02-11-2005, 09:36 PM
He said to vertically center text...
Say you have a div that is 500px high. This is how you would get the text in the center (horizontally and vertically).
<p class="centered">Centered text.</p>
02-11-2005, 09:39 PM
How to vertically align something? I wonder if this has been asked before...
* harp music and a slow fade to.... *
Powered by vBulletin® Version 4.2.2 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.