T
T
TomatPasta2018-08-03 18:08:29
HTML
TomatPasta, 2018-08-03 18:08:29

Bootstrap 4 how to write order correctly?

Good day. It is necessary to change the order of the blocks on the mobile screen, but they change the order with a large one.

<div class="col-sm-6 order-sm-2">
            111
        </div>
        <div class="col-sm-6 order-sm-1">
            222
        </div>

With such a code, in theory, on the desktop, 111 should go first, followed by 222, and when reduced to a mobile one, they change places, but for me it’s the other way around ... don’t kick much.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
E
Earphone, 2018-08-03
@Earphone

<div class="container">
  <div class="row">
       <div class="col-md-6 order-lg-1  order-sm-2">111</div>
       <div class="col-md-6  order-lg-2 order-sm-1">222</div>
  </div>
</div>

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question