title: Size image to container while maintaing aspect ratio in CSS?
body: <p>I have a bunch of images of different (unknown) dimensions.</p>
  
  <p>I want to drop these images into a div and have them automatically conform to the dimensions of the div, while maintaining their aspect ratio.  </p>
  
  <p>In other words, if the image is wider than high, the width will be 100%, and the height will scale accordingly.  If the image is higher than wide, the height will be 100%, and the width will scale accordingly.</p>
  
  <p>Is there any way to do this in pure css?</p>
  
  <p>Thanks</p>