HTML CSS examples for Bootstrap:Form Control
Inline Checkboxes and Radios
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>Example of Bootstrap 3 Inline Checkboxes and Radios</title> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script> </head><!-- ww w.ja v a 2s. c om--> <body> <div> <form> <h4>Choose your favorite sports</h4> <div> <label class="checkbox-inline"><input type="checkbox" name="sports"> HTML</label> <label class="checkbox-inline"><input type="checkbox" name="sports"> CSS</label> <label class="checkbox-inline"><input type="checkbox" name="sports"> Javascript</label> </div> <hr> <h4>Choose your gender</h4> <label class="radio-inline"><input type="radio" name="gender"> Male</label> <label class="radio-inline"><input type="radio" name="gender"> Female</label> </form> </div> </body> </html>