How do I
vertically center an image (crop top and bottom)
have the image size to have width:100%
it's parent having overflow hidden?
some solutions I've tried was Align image in center and middle within div and as well as others.
html
<div>
<a href="#"><img src=".."></a>
</div>
css
div {
height:60px;
width:200px;
position: relative;
display: block;
overflow:hidden;
}
img {
vertical-align:middle;
width:100%;
}
heres a codepen for it http://codepen.io/anon/pen/oXRoxp
thanks!