0
How can i fit the background image? My image has 2560x1600 pixels
Background image stretch/fit
3 Respostas
+ 2
in css it is background: url(flower.jpg);
width: 100%;
height: 100%;
there is html attribute too
<IMG src="flower.jpg" width=100% height=100% ...
this will auto adjust the image even if it is big. there is cover
+ 1
background:url('...blabla.jpg');
background-size: 100% 100%; OR background-size: 100%;
0
background: url(my-image.jpg) no-repeat;
background-size: cover;