Oleg Dats Oleg Dats - 25 days ago 9
CSS Question

How to vertically align text in input type="text"?

There is

<input type="text" />
I need to set vertical alignment of the entered text. For example middle or top.
http://jsfiddle.net/eSPMr/

Answer Source

Use padding to fake it since vertical-align doesn't work on text inputs.

jsFiddle example

CSS

.date-input {     
    width: 145px;
    padding-top: 80px;
}‚Äč