我正在嘗試創建類似於https://www.pinterest.com/主頁,其中高度根據Div &的內容決定,所有div都使用引導程序自動調整它。如何在引導程序中獲取div的動態高度
我試圖這樣做,但它不按預期工作。 這裏是我試過的小提琴的鏈接http://jsfiddle.net/gmm2jcn5/
在小提琴中,我們可以看到2個div之間有白色的差距,我想消除這個差距。
.col-xs-6 {
border: 1px solid black;
}
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css" rel="stylesheet"/>
<script src="http://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/2.0.1/bootstrap.min.js"></script>
<div class="row">
<div class="col-xs-6">
<p class="inntertopheading">heading</p>
<div class="hr"></div>
<div class="innter-md-text">
text
<div class="spacer10"></div>
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
</div>
</div>
<div class="col-xs-6">
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's. Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's. Lorem Ipsum is simply dummy text of the printing and typesetting industry.
</div>
<div class="col-xs-6">
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's. Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's. Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's. Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's. Lorem Ipsum is simply dummy text of the printing and typesetting industry.
</div>
<div class="col-xs-6">
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's
</div>
</div>
請包括最短的工作代碼在這裏爲紐帶,也許哪一天到期使得這個問題毫無用處給他人。謝謝! – Shawn