I am using bootstrap and i find the height of the text field is too small.It\'s like less than 10px.I am wondering if it is small or i made some mistakes.
I used firebug
Adding <!DOCTYPE HTML>
should fix this. The same question was asked here: Text input rendering issue with Twitter Bootstrap
Incase the top answer didn't help
I had <!DOCTYPE html>
already and it wasn't the problem for me. I don't know what is the problem, but
I fixed it with this in my css:
input[type=text], input[type=password], input[type=email], input[type=tel] {
height: 28px !important;
}
It's a workaround and I'm not sure if it has some side effects.
I don't know why if I open a clean new HTML5 page it works but after I add some code I don't know why it happens. So I just open the bootstrap.min.css file and search:type="text"
and there there is height property and I change it to min-height for it have to be working.
See my solution here in a similar thread.
Basically, the text file encoding was causing all my trouble. It manifested in such minute differences across browsers that I wasted hours fiddling with CSS thinking that was the cause.
Yes the total height
is 28px
because padding & border also add height
to that input
like this:
height 18px +
4px padding-top +
4px padding-bottom +
1px border-top +
1px border-bottom =
Total 28px height