Bootstrap Tutorial - Clear fix to start new line








The following code shows how to clear fix to start new line.

Example

<!DOCTYPE html>
<html>
<head>
<script type='text/javascript'
  src='http://code.jquery.com/jquery-git2.js'></script>
<script type='text/javascript'
  src="http://netdna.bootstrapcdn.com/bootstrap/3.0.0/js/bootstrap.min.js"></script>
<link rel="stylesheet" type="text/css"
  href="http://netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css">
<style type='text/css'>
/* Optional theme */
@import url('http://netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap-theme.min.css');
body {<!--from   w w  w. jav a 2s .  c  o  m-->
  margin: 10px;
}
</style>
</head>
<body>
  <form class="form-horizontal" role="form">
    <div class="form-group">
      <label for="inputProposalname"
        class="col-lg-2 control-label col-sm-2 col-md-2 col-xs-2">Proposal
        name</label>
      <div class="col-lg-3 col-sm-2 col-md-2 col-xs-2">
        <input type="text" class="form-control" maxlength="255"
          required="required" id="email" placeholder="Proposalname" />
      </div>
    </div>
    <div class="clearfix"></div>
    <div class="form-group">
      <label for="inputClientId" class="col-lg-2 control-label">Client
        Id</label>
      <div class="col-lg-3">
        <input type="number" class="form-control" required="required"
          id="clientid" placeholder="Client id">
      </div>
    </div>
    <div class="clearfix"></div>
    <div class="form-group">
      <label for="inputUpdateddatetime" class="col-lg-2 control-label">Updateddatetime</label>
      <div class="col-lg-3">
        <input type="datetime" class="form-control" required="required"
          id="updateddatetime" placeholder="Updated datetime">
      </div>
    </div>
    <div class="clearfix"></div>
    <div class="form-group">
      <div class="col-lg-offset-2 col-lg-10">
        <button type="submit" class="btn btn-default">Create</button>
      </div>
    </div>
  </form>
</body>
</html>

Click to view the demo