We have an input file on our website that is not as high as in the demo (see below, I exaggerated it to show the problem better), but we canโt get the file name in the center vertically - only the button with the centers in the vertical. Usually this is not a problem, since we usually adhere to the default style, but in this case the client wants to get a border at this input, so that the right border is aligned upwards with a few right-aligned buttons. The height in our case is 23px (the same for the height of the line).
See http://jsfiddle.net/UK72P/ for a demo. As far as I know, this only happens in Chrome and possibly in IE9 / 8 (it will be confirmed in the near future). Code in jsfiddle:
HTML
<input type="file">โ
CSS
input { display: inline-block; height: 40px; line-height: 40px; border: 1px solid #999; }
Is there any property that I donโt know about, or is it just not possible?
Thanks in advance Richard
Clarkeyboy
source share