i have a problem properly vertical-align my images. I have div
container with a height and line-height of 40px. Inside there is another div
containing 2 img
and one span
. The images' height is set to 30px so the images are scaled down.
The vertical-align property of the img
is set to middle. However the generated offsets are 8px on top and 2px on the bottom - in Firefox as well as in Chrome. If i set the vertical-align property to top
or baseline
the images are on the top edge, setting it to bottom
moves them to the bottom (no spacing at all).
I tried to find a way to properly align them without extra markup but i cannot seem to find anything. I also tried the solution for How to vertically align an image inside div, but i had no luck with that.
I have created a jsfiddle to illustrate the problem: http://jsfiddle.net/pbQDS/
Hope you can help! Thanks!