Bootstrap 3 Template

This is a simple Twitter Bootstrap 3 template. You can fork it to get a ready to use Bootstrap 3 fiddle.

by Jawad Ameen

HTML

<script src="//netdna.bootstrapcdn.com/bootstrap/3.0.0/js/bootstrap.min.js"></script>
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css">
<script src="http://abpetkov.github.io/switchery/dist/switchery.min.js"></script>
<link rel="stylesheet" href="http://abpetkov.github.io/switchery/dist/switchery.min.css">
<form id="fromAcceptCases" role="form" action="/" method="POST">
      <div class="pull-right checkbox">
        <label>
          Some text
        </label>
        <input id="chkAcceptCases" name="acceptCases" type="checkbox" class="js-switch js-check-change" onchange="testing()" />
      </div>
    </form>

CSS

/* Latest compiled and minified CSS included as External Resource*/

/* Optional theme */
@import url('//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap-theme.min.css');

body {
    margin: 10px;
}

JavaScript

var elem = document.querySelector('.js-switch');
var init = new Switchery(elem);

var changeCheckbox = document.querySelector('.js-check-change');

/* changeCheckbox.onchange = function() {
   alert(changeCheckbox.checked);
} */

var testing = function() {
   alert(changeCheckbox.checked);
};