Forum Moderators: open
I'm looking for a tidy way to deal with images that are larger than the container that they are held within. So, for example -
<div class=mydiv><img src='toobig.jpg'></div>
where the div has a fixed width set in its CSS.
I find with the div that the img just breaks out of the right hand side. I was rather hoping that infact it would be clipped somehow with the div taking priority.
Any ideas?
thanks
tony
Lastly, you should be able to have the image automatically resized to non-overflow. Just put max-width/max-height as 100%. The issue with this is that some browsers do not support it.