我是 Bootstrap 的新手。我在更改小屏幕中的列顺序时遇到问题。它应该如下所示。有什么想法吗?
MD & LG
[a] [b]
[c] [d]
sm & xs
[A]
[b]
[d]
[c]
我已经尝试过仅针对“sm”的推拉组合,但它会随着其他屏幕尺寸“md”和“lg”而改变..
.new_section {
text-align: center;
margin: 40px 0;
}
.about_bg {
background-color: rgba(252, 160, 0, 0.76);
}
.jumbo_text > h1 {
height: 200px;
line-height: 200px;
color: #FFFFFF;
}
.jumbo_text > p {
color: #666666;
padding: 20px 0;
overflow: hidden;
}
.arch_prof_bg {
background-color: rgba(252, 160, 0, 0.76);
}
.proj_heading_bg {
background-color: rgba(129, 86, 11, 0.8);
}
.proj_heading_bg > h1 {
margin: 20px;
color: #FFFFFF;
}
<section class="new_section">
<div class="container">
<div class="row" id="about">
<div class="col-md-6 jumbo_text about_bg">
<h1>Our Company</h1>
</div>
<div class="col-md-6 jumbo_text">
<P class="text-left">
It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout. The point of using Lorem Ipsum is that it has a more-or-less normal distribution of letters, as opposed to using 'Content here,
content here', making it look like readable English. Many desktop publishing packages and web page editors now use Lorem Ipsum as their default model text, and a search for 'lorem ipsum' will uncover many web sites still in their infancy. Various
versions have evolved over the years, sometimes by accident, sometimes on purpose (injected humour and the like).
</P>
</div>
</div>
<div class="row" id="arch_prof">
<div class="col-sm-6 col-sm-pull-6 jumbo_text">
<P class="text-left">
It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout. The point of using Lorem Ipsum is that it has a more-or-less normal distribution of letters, as opposed to using 'Content here,
content here', making it look like readable English. Many desktop publishing packages and web page editors now use Lorem Ipsum as their default model text, and a search for 'lorem ipsum' will uncover many web sites still in their infancy. Various
versions have evolved over the years, sometimes by accident, sometimes on purpose (injected humour and the like).
</P>
</div>
<div class="col-sm-6 col-sm-push-6 jumbo_text arch_prof_bg">
<h1>Architect Profile</h1>
</div>
</div>
</div>
</section>
最佳答案
这是东西
<div class="row">
<div class="col-md-6">A</div>
<div class="col-md-6">B</div>
</div>
<div class="row">
<div class="col-md-6 col-md-push-6">D</div>
<div class="col-md-6 col-md-pull-6">C</div>
</div>
关于html - Bootstrap : Changing column order,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32987294/