3
I have a question about divs
with imagens
in the case, the doubt is as follows:
- If I have a
div
, with400x400
, how do I make an image with200x400
(or other resolution) fit by occupying the total size of thediv
, without distorting theimagem
, and without using thebackground
ofcss
For example:
*the first imagem
is how the end result would be, the way it is said, the second is how it normally looks, the imagem
whole is placed in the div
, always leaving white space, both vertical
, as horizontal
, the image should be adjusted according to the size of the div
.
Problem is supported browsers. But it is a good option when everyone else stops using IE.
– Diego Souza
@IE and EDGE are really a problem as always kkk but this property using prefixes is already supported by 91.5% of browsers in Brazil according
– Lennon S. Bueno
Chic 10 even. I will start using.
– Diego Souza