Create page header with pull right/left

Description

The following code shows how to create page header with pull right/left.

Example


<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" type="text/css"
  href="http://netdna.bootstrapcdn.com/twitter-bootstrap/2.2.0/css/bootstrap-combined.min.css">
<script type='text/javascript'
  src="http://netdna.bootstrapcdn.com/twitter-bootstrap/2.2.0/js/bootstrap.min.js"></script>
<style type='text/css'>
.btn-group {<!--   w  w w  . ja v a2s .  c  o  m-->
  bottom: 15px;
  position: relative;
  top: 15px;
}
</style>
</head>
<body>
  <div class="container">
    <section>
      <div class="page-header">
        <h3 class="pull-left">The header</h3>
        <div class="pull-right">
          <div class="btn-group">
            <button class="btn btn-primary">Actions</button>
            <button class="btn btn-primary dropdown-toggle"
              data-toggle="dropdown">
              <span class="caret"></span>
            </button>
            <ul class="dropdown-menu pull-right">
              <li><a href="#">Action</a></li>
              <li><a href="#">Another Action</a></li>
            </ul>
          </div>
        </div>
        <div class="clearfix"></div>
      </div>
      Contents
    </section>
  </div>
</body>
</html>

Click to view the demo





















Home »
  Bootstrap »
    Example »




Accordion
Alert
Auto Complete
Badge
Breadcrum
Button
Carousel
Collapse
Dialog
Dropdown
Form
Icon
Jumbotron
Label
Layout
List
List Group
Media
Navigation Bar
Pager
Page Header
Panel
Paragraph
Pills
Popover
ProgressBar
ScrollSpy
Switch
Tab
Table
Thumnail
Tooltip
Tree
Well