[英]how to make my images responsive?
大家好,都使用twitters引导程序: http : //twitter.github.io/bootstrap/base-css.html#tables
我在徘徊如何阻止这种情况的发生: http : //img823.imageshack.us/img823/6606/screenshotfrom201306071.png我希望图像随窗口调整大小,直到它从bootsrap的文本上方突出为止。
链接: http : //www.prxa.info/articles/category/1用户:test.prxa。 通过:测试
我需要此处的图片最大为350px,因为某些人包括的图片非常大,必须调整大小以免将其弄乱。
这是我对缩略图区域和内部图像的自定义CSS:
.thumbnail
{
width: 350px;
height: 220px;
display: table-cell;
vertical-align: middle;
}
img.tagline-img
{
max-width: 350px;
max-height: 220px;
}
不是最好的响应技术,但它将使其适合
只需使用
img.tagline-img {
width:100%;
}
刚刚在您的网站上测试
取自bootstrap:
img{
border:0;
max-width:100%; /* Part 1:Set a maxium relative to the parent */
width:auto\9; /* IE7-8 need help adjusting responsive images */
height:auto; /* Part 2:Scale the height according to the width,
otherwise you get stretching */
-ms-interpolation-mode:bicubic
}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.