"Buying Selling Radio Buttons"
Bootstrap 3.3.0 Snippet by kobusvanwykk

<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css"> <script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/js/bootstrap.min.js"></script> <script src="//code.jquery.com/jquery-1.11.1.min.js"></script> <!------ Include the above in your HEAD tag ----------> <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css"> <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,600,700' rel='stylesheet' type='text/css'> <link rel="stylesheet" href="https://dl.dropboxusercontent.com/u/86701580/mypersonalcdn/renda/renda-icon-font.css"> <div class="container"> <h3>Buying Selling Radio Button Group</h3> <div class="buying-selling-group" id="buying-selling-group" data-toggle="buttons"> <label class="btn btn-default buying-selling"> <input type="radio" name="options" id="option1" autocomplete="off"> <span class="radio-dot"></span> <span class="buying-selling-word">Selling</span> </label> <label class="btn btn-default buying-selling"> <input type="radio" name="options" id="option2" autocomplete="off"> <span class="radio-dot"></span> <span class="buying-selling-word">Buying</span> </label> </div>
.buying-selling.active { background: #7BB712; } .buying-selling { width: 130px; padding: 10px; position: relative; } .buying-selling-word { font-size: 15px; font-weight: 600; margin-left: 22px; } .radio-dot:before, .radio-dot:after { content: ""; display: block; position: absolute; background: #fff; border-radius: 100%; } .radio-dot:before { width: 20px; height: 20px; border: 1px solid #ccc; top: 10px; left: 16px; } .radio-dot:after { width: 12px; height: 12px; border-radius: 100%; top: 14px; left: 20px; } .buying-selling.active .buying-selling-word { color: #fff; } .buying-selling.active .radio-dot:after { background: #426C2A; } .buying-selling.active .radio-dot:before { background: #fff; border-color: #699D17; } .buying-selling:hover .radio-dot:before { border-color: #adadad; } .buying-selling.active:hover .radio-dot:before { border-color: #699D17; } .buying-selling.active .radio-dot:after { background: #426C2A; } .buying-selling:hover .radio-dot:after { background: #e6e6e6; } .buying-selling.active:hover .radio-dot:after { background: #426C2A; } @media (max-width: 400px) { .mobile-br { display: none; } .buying-selling { width: 49%; padding: 10px; position: relative; } }
$(window).resize(function() { if ($(window).width() <= 600) { $('#prop-type-group').removeClass('btn-group'); $('#prop-type-group').addClass('btn-group-vertical'); } else { $('#prop-type-group').addClass('btn-group'); $('#prop-type-group').removeClass('btn-group-vertical'); } });

Related: See More


Questions / Comments: