2016-05-23 18 views
0

我需要根據MD和/或設備的類型LG對齊的div如圖附加圖像..如何使用bootstrap根據lg和/或md類型對齊div?

隨着我已經寫..它是推動下面第3欄第格欄9格的代碼..

請幫我解決這個問題..

HTML我使用的是...

<div class="col-lg-12 col-md-9"> 

col 1 <div class="col-lg-3 col-md-3 col-lg-push-9"> col 3 </div> <div class="col-lg-9 col-md-9"> col 2 </div>

回答

0

這可以爲你工作。使用「拉右」類,而不是您擁有的推送類。這應該做的伎倆。

這是一個LG和MD例如,你要求:

<div class="col-lg-12 col-md-9"> 
    <!-- Content --> 
</div> 
<div class="col-lg-3 col-md-3 pull-right"> 
    <!-- Content --> 
</div> 
<div class="col-lg-9 col-md-9"> 
    <!-- Content --> 
</div> 

這是一個LG,MD,SM如果你想在較小的屏幕尺寸增加額外的空間,一邊

<div class="col-lg-12 col-md-9 col-sm-8"> 
    <!-- Content --> 
</div> 
<div class="col-lg-3 col-md-3 col-sm-4 pull-right"> 
    <!-- Content --> 
</div> 
<div class="col-lg-9 col-md-9 col-sm-8"> 
    <!-- Content --> 
</div> 

在這裏看到一個例子:Example

商祺!

+0

非常感謝你AbboMuren ..它的工作! – Anant

+0

歡迎你。你可能想看看這些鏈接: 用於引導 佈局建模: http://www.layoutit.com/build 邊欄插件,用於引導: http://startbootstrap.com/template-overviews /簡單側邊欄/ –