Renegade Rob Renegade Rob - 5 months ago 5x
CSS Question

CSS Body Image stretches when on a mobile device

I have the following CSS script that I would like help with. When its on a PC it looks fine, but when its on a mobile device its stretched. Is there anything I can add to it to keep the aspect ratio please?

body {
font-family: 'Open Sans', sans-serif;
background:url(../images/bg.jpg) no-repeat center fixed;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
background-size: 100% 100%;

Thanks all



If you remove background-size: 100% 100% it should work for you.