mercredi 28 janvier 2015

CSS "background-position: bottom" Imperfect on Mobile Browsers




body
{
background-color: #000000;
background-image: url('http://ift.tt/15VJ8lx');
background-repeat: no-repeat;
background-attachment: fixed;
background-position: center bottom;
background-size: cover;
}

a
{
color: #ffffff;
}



<a>Hello, world!</a>


A site I'm developing has a background-image that fills the viewport and is anchored to the bottom. It works perfectly on PC, but mobile browsers on Android anchor the background-image to the bottom of the last element if the content doesn't fill the screen, leaving a blank space below it. How can I fix this to make the background-image correctly fill the screen on Android?





Aucun commentaire:

Enregistrer un commentaire