how to center text vertically in html using css only

Posted by stanleyxu2005 on Stack Overflow See other posts from Stack Overflow or by stanleyxu2005
Published on 2010-05-31T11:37:22Z Indexed on 2010/05/31 11:42 UTC
Read the original article Hit count: 255

Filed under:
|
|
|
|

Hi All,

i have a very simple html. due to some limitations, i cannot modify the html content. I want to center the text vertically only using css.

<html>
<head>...</head>
<body>
<div>Ops, the webpage is currently not available</div>
</body>
</html>

Note that the size of the html can be variable.

In additional, if the text cannot be displayed in one line, it should be broken into multiple lines.

Is it possible?

© Stack Overflow or respective owner

Related posts about html

Related posts about css