So I got this input field that I expect to be 34px high (border 2px + padding 2 * 10px + text 12px), but it ends up higher than that:
- 37px in Firefox 15
- 37px in Chrome 22
- 36px in IE9
Question: why is my input field not 34px high?
The HTML / CSS
<input type="text" class="input" placeholder="Why is this not 34px high?">
<style>
.input {
border: 1px solid #000;
font-family: Arial;
font-size: 12px;
padding: 10px;
width: 200px;
}
</style>
Update: Defining line-height (12px) and setting box-sizing (border-box) does not help - updated fiddle