Reputation: 3696
I need to design something the first one in the picture below, there should not be left or right padding.
What I really want to do is:
Upvotes: 0
Views: 145
Reputation: 9468
You don't need to change anything in native Bootstrap to achieve this if you have two <div>
s in the same <row>
. Just move your left
and right
classes into the same line as col-xs-4
/ col-xs-8
. Also you shouldn't have a <section>
as a parent of your <container>
, you should move it be a child of container (though I removed it below, since it seems unecessary).
Example:
<div class="container"> //change this to container-fluid if you want full screen width
<div class="row">
<div class="col-xs-4 left">
</div>
<div class="col-xs-8 right">
</div>
</div>
</div>
Upvotes: 3
Reputation: 797
Create a nopadding class like this one:
.nopadding {
padding: 0 !important;
margin: 0 !important;
}
If you add that class to your column divs there will be no padding on them.
Upvotes: 0