Bootstrap Tutorial - Use fluid row and span12








The following code shows how to use fluid row and span12.

Example

<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" type="text/css"
  href="http://netdna.bootstrapcdn.com/twitter-bootstrap/2.3.2/css/bootstrap-combined.min.css">
<style type='text/css'>
html, body {<!--  w  w w .j a  v  a  2  s  .c  o  m-->
  height: 100%
}

#side-panel {
  float: left;
  width: 240px;
  padding: 10px 20px 10px 20px;
  height: 100%;
  background-color: #1db34f;
  border-right: 1px solid #dddddd;
  text-align: center;
}

#center-panel {
  margin-left: 280px;
  background-color: #ddd;
  text-align: center;
}

#center-panel .row-fluid {
  overflow: auto;
}

#center-panel .large {
  height: 400px;
  padding: 10px;
  background-color: #f17f49
}
</style>
</head>
<body>
  <div id="side-panel">
    <p>I'm the side panel</p>
  </div>
  <div id="center-panel" class="container-fluid">
    <p>I'm the center panel</p>
    <div class="row-fluid">
      <div class="span12">
        <p class="large">First row</p>
      </div>
    </div>
    <div class="row-fluid">
      <div class="span12">
        <p class="large">Second row</p>
      </div>
    </div>
  </div>
</body>
</html>

Click to view the demo