"Buying Selling Radio Buttons"
Bootstrap 3.3.0 Snippet by kobusvanwykk

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<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>
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
.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;
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
1
2
3
4
5
6
7
8
9
10
11
$(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');
}
});
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Related: See More


Questions / Comments: