.col-*-pull-* - Changes the order of the grid columns - HTML CSS Bootstrap

HTML CSS examples for Bootstrap:Grid Layout

Description

.col-*-pull-* - Changes the order of the grid columns

Demo Code

ResultView the demo in separate window

<!DOCTYPE html>
<html>
<head>
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.2/css/bootstrap.min.css">
  <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
  <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.12.6/umd/popper.min.js"></script>
  <script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.2/js/bootstrap.min.js"></script>
</head><!-- w  w  w  . j a  v a  2s  .c  om-->
<body>

<div class="container-fluid">
  <h1>Push and Pull</h1>
  <p>Resize the browser window to see the effect.</p>
  <div class="row">
    <div class="col-sm-4 col-sm-push-8" style="background-color:lavender;">.col-sm-4 .col-sm-push-8</div>
    <div class="col-sm-8 col-sm-pull-4" style="background-color:lavenderblush;">.col-sm-8 .col-sm-pull-4</div>
  </div>
  <div class="row">
    <div class="col-sm-6 col-sm-push-6" style="background-color:lavender;">.col-sm-6 .col-sm-push-6</div>
    <div class="col-sm-6 col-sm-pull-6" style="background-color:lavenderblush;">.col-sm-6 .col-sm-pull-6</div>
  </div>

  <div class="row">
    <div class="col-sm-6 col-sm-push-6" style="background-color:lavender;">.col-sm-6 .col-sm-push-6</div>
    <div class="col-sm-6 col-sm-pull-6" style="background-color:lavenderblush;">.col-sm-6 .col-sm-pull-6</div>
  </div>

</div>

</body>
</html>

Related Tutorials