Bootstrap Tutorial - Create nested responsive grid








The following code shows how to create nested responsive grid.

Example

<!DOCTYPE html>
<html>
<head>
<script type='text/javascript'
  src='http://code.jquery.com/jquery-1.8.3.js'></script>
<script type='text/javascript'
  src="http://netdna.bootstrapcdn.com/twitter-bootstrap/2.2.2/js/bootstrap.min.js"></script>
<link rel="stylesheet" type="text/css"
  href="https://dl.dropbox.com/u/2665617/bootstrap/css/bootstrap.min.css">
<style type='text/css'>
.span3 {<!--   w w  w . j  a v  a2 s.  co m-->
  background-color: grey;
}

.span6 {
  background-color: yellow;
}

.span9 {
  background-color: blue;
}
</style>
</head>
<body style='margin:30px'>
  <div class="container">
    <div class="row">
      <div class="span9">
        <div class="row">
          <div class="span6">nested col</div>
          <div class="span3">nested col</div>
        </div>
      </div>
      <div class="span3">span 3</div>
    </div>
  </div>
</body>
</html>

Click to view the demo