Bootstrap classes for creating columns with space

Asked

Viewed 9,637 times

2

I want to understand the classes of Bootstrap, when using the span and offset, and how to give a space between the columns?

1 answer

3


To move the columns you use the class .col-md-offset-* . Class increments left margin of column. For example, .col-md-offset-4 move .col-md-4 after 4 columns.

<div class="row">
  <div class="col-md-4">.col-md-4</div>
  <div class="col-md-4 col-md-offset-4">.col-md-4 .col-md-offset-4</div>
</div>
<div class="row">
  <div class="col-md-3 col-md-offset-3">.col-md-3 .col-md-offset-3</div>
  <div class="col-md-3 col-md-offset-3">.col-md-3 .col-md-offset-3</div>
</div>
<div class="row">
  <div class="col-md-6 col-md-offset-3">.col-md-6 .col-md-offset-3</div>
</div>

And the result is this

render html

  • <div class="Row"> <div class="col-Md-6 col-Md-offset-3">. col-Md-6 . col-Md-offset-3</div> </div> worked perfectly.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.