Bootstrap:网格项目未针对991-1200px分辨率对齐

时间:2016-03-15 20:36:42

标签: html css twitter-bootstrap twitter-bootstrap-3

我有一个包含6个项目的Bootstrap网格,我需要它们对齐。
对于大多数分辨率,它们看起来很好,但是当屏幕分辨率为991px - 1200px时,网格上的项目停止对齐:

enter image description here

我的HTML代码:

     <div class="container">
        <section class="row no-pad">
            <div class="col-sm-6 col-md-4">
                <div class="thumbnail"> 
                    <i class="fa fa-usd"></i>
                    <div class="caption">
                        <h3></h3>
                        <p></p>
                    </div>
                </div>
            </div>

            <div class="col-sm-6 col-md-4">
                <div class="thumbnail"> 
                    <img src="img/abtesting.png">
                    <div class="caption">
                        <h3></h3>
                        <p></p>
                    </div>
                </div>
            </div>

            <div class="col-sm-6 col-md-4">
                <div class="thumbnail"> 
                    <img src="img/roi.png">
                    <div class="caption">
                        <h3></h3>
                        <p></p>
                    </div>
                </div>
            </div>

            <div class="clearfix visible-lg"></div>

            <div class="col-sm-6 col-md-4">
                <div class="thumbnail"> 
                    <img src="img/crm-remarketing.png">
                    <div class="caption">
                        <h3></h3>
                        <p></p>
                    </div>
                </div>
            </div>

            <div class="col-sm-6 col-md-4">
                <div class="thumbnail"> 
                    <img src="img/segment.png" alt="analytics-icon">
                    <div class="caption">
                        <h3></h3>
                        <p></p>
                    </div>
                </div>
            </div>

            <div class="col-sm-6 col-md-4">
                <div class="thumbnail"> 
                    <img src="img/multi-channel.png">
                    <div class="caption">
                        <h3>/h3>
                        <p></p>
                    </div>
                </div>
            </div>
        </section> 
    </div>

没有CSS代码,Bootstrap版本3.3.5

如何使网格项对齐991-1200px分辨率?

1 个答案:

答案 0 :(得分:0)

您可以这样做,请参阅小提琴示例https://jsfiddle.net/DIRTY_SMITH/7oe5kh9L/28/

在第3和第4个div之间添加<div class="col-md-12"></div>