I have an image in a div in a div in a div. I would like to resize the image to fit in the div , keeping aspect ratio. it works in firefox, but i can’t get it to work in webkit based browsers.
It works in Firefox if the width is set to width: -moz-available; Is there anything similar in Chrome?
Set the image to
max-width: 100%. If you need high quality scaling in IE7 or lower, also add anAlphaImageLoaderfilter withsizingMethod='scale'.