html - Size a background image? -
i have div 200px 200px.
it's background image 500px x 500px.
is there way make sure entire background image fits div? know can size css3 i'm looking solution older browsers.
thanks
is there way make sure entire background image fits div?
i know can size css3 i'm looking solution older browsers.
there no other standard way scale background image.
older versions of internet explorer can supported via non-standard filter
property , alphaimageloader
.
/* untested */ background-image: url(images/someimage.png); background-resize: cover; filter: "progid:dximagetransform.microsoft.alphaimageloader(src='images/someimage.png',sizingmethod='scale')"; -ms-filter: "progid:dximagetransform.microsoft.alphaimageloader(src='images/someimage.png',sizingmethod='scale')";
alternatively, hack, use <img>
element, , absolutely position behind content. content image though, wouldn't clean hack.
Comments
Post a Comment