img {
max-width: 100% !important; /* Set a maxium relative to the parent */
width: auto\9 !important; /* IE7-8 need help adjusting responsive images */
height: auto; /* Scale the height according to the width, otherwise you get stretching */
vertical-align: middle;
border: 0;
我遇到了一个需要自动缩小我的文本包装宽度下面的图片。
例如:
<figure>
<img src="mypicture.jpg" />
<figcaption>
This is a long description.This is a long description.This is a long description.
</figcaption>
</figure>
现在我想要一个围绕img和figcaption的border,因为我有很多不同宽度的图像。所以我想自动缩小fi