How do I set the the max-height:270px
and height:auto
simultaneously such that if a content(image) is too large it should shorten its dimensions and put it under 270px
, else it should be an auto
height.
I tried with overflow-Y
but I dont want a scrollbar, just a mini version of the pic. How can I do that?
CHANGED CODE :: TRY IT
img{
height:100%;
max-height:270px;
}
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