S
S
sabanovvv2014-07-01 23:39:02
css
sabanovvv, 2014-07-01 23:39:02

How to display columns in bootstrap?

There is a site 1200px wide.
Task: to display 3 columns on the entire width of the screen,
I do this:

<div class="row">
     <div class="col-lg-4"></div>
     <div class="col-lg-4"></div>
     <div class="col-lg-4"></div>
</div>

3 horizontal columns are displayed on a screen width of 970px
what am I doing wrong?

Answer the question

In order to leave comments, you need to log in

6 answer(s)
F
Flaker, 2014-07-02
@Flaker

You need to wrap everything in a .container-fluid block .
All parent elements of the .container-fluid block should be width: 100%
If you're doing it from a layout, check to see if there's something like a .wrapper element that is limited in width. It should be made width: 100% .

Y
yttrium, 2014-07-01
@yttrium

row must be placed in container or container-fluid
grid

Y
Yuri Lobanov, 2014-07-02
@iiil

There is a site 1200px wide.
Task: display 3 columns to the full width of the screen

What, am I the only one who is confused by the fact that two phrases contradict each other?
Author, read the documentation.

I
Igor Tkachenko, 2014-07-02
@foozzi

<div class="col-xs-12">
     <div class="col-xs-4"></div>
     <div class="col-xs-4"></div>
     <div class="col-xs-4"></div>
</div>

V
Volodymyr Godyak, 2014-07-02
@wmgodyak

<div class="container">
        <div class="row">
            <div class="col-lg-4">col-1</div>
            <div class="col-lg-4">col-2</div>
            <div class="col-lg-4">col-3</div>
        </div><!-- .container-->
    </div><!-- .row-->

O
Olexandr Dmukhovskiy, 2014-07-02
@olexandrbig

Hello.
The difficulty is that Bootstrap does not have a block width
Cause you need your block

<div class="w1200">
 <div class="row">
  <div class="col-lg-4">col-1</div>
  <div class="col-lg-4">col-2</div>
  <div class="col-lg-4">col-3</div>
 </div>
</div>

.w1200{
width:1200px;
margin:0 auto;
}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question