1
我要展示我的照片有問題,在這裏是如何看起來像:自舉圖片顯示
這裏是我怎麼想它是:
一切圖片應該在他的專欄的圖片下。下面是代碼:
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<div class="row">
<div class="col-md-3">
<img src="http://placehold.it/1080x1080" class="img-responsive" style="margin-bottom:25px;">
</div>
<div class="col-md-3">
<img src="http://placehold.it/1080x1350" class="img-responsive" style="margin-bottom:25px;">
</div>
<div class="col-md-3">
<img src="http://placehold.it/566x1080" class="img-responsive" style="margin-bottom:25px;">
</div>
<div class="col-md-3">
<img src="http://placehold.it/1080x1080" class="img-responsive" style="margin-bottom:25px;">
</div>
<div class="col-md-3">
<img src="http://placehold.it/1080x1080" class="img-responsive" style="margin-bottom:25px;">
</div>
<div class="col-md-3">
<img src="http://placehold.it/1080x1350" class="img-responsive" style="margin-bottom:25px;">
</div>
<div class="col-md-3">
<img src="http://placehold.it/566x1080" class="img-responsive" style="margin-bottom:25px;">
</div>
<div class="col-md-3">
<img src="http://placehold.it/1080x1080" class="img-responsive" style="margin-bottom:25px;">
</div>
</div>
您需要使用其中一種技巧。使用CSS,您可以創建列並製作像http://w3bits.com/css-masonry/的佈局,或者您可以使用像Masonry這樣的js庫https://masonry.desandro.com/ –