I'm trying to vertically align text in two table columns, one of which also has a text input control. Basic code such as:
<td>Caption</td><td>Enter here <input type="text"></td>
No matter how I apply vertical-align to one or both columns, 'Caption' is not on the same level as 'Enter here'. Most times 'Caption' is higher. What's the solution?
Try:
td, input {
vertical-align: middle;
}
If that doesn't work, you will need to post more code to get a good answer.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With