css - vertical align html form -


i'm looking center textbox , submit button on page both vertically , horizontally following code puts in top center. how can center page? it's it's ignoring vertical-align setting.

<div style="text-align:center; vertical-align:middle">     <form action="save_thought.php" method="post">         <input type="text" name="thought"><br>         <input type="submit" value="submit">     </form> </div> 

you can use position:absolute demo http://jsfiddle.net/kevinphpkevin/u8dzr/

div#form-wrapper {     position:absolute;     top:50%;     right:0;     left:0; } 

Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Socket.connect doesn't throw exception in Android -

iphone - How do I keep MDScrollView from truncating my row headers and making my cells look bad? -