forked from snapappointments/bootstrap-select
-
Notifications
You must be signed in to change notification settings - Fork 0
/
test.html
132 lines (120 loc) · 4.38 KB
/
test.html
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
<!DOCTYPE html>
<html>
<head>
<title>Bootstrap-select test page</title>
<meta charset="utf-8">
<link rel="stylesheet" type="text/css" href="dist/css/bootstrap-select.css">
<!-- 3.2 -->
<link href="//netdna.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css" rel="stylesheet">
<!-- -->
<!-- 2.3.2 ->
<link href="//netdna.bootstrapcdn.com/twitter-bootstrap/2.3.2/css/bootstrap-combined.min.css" rel="stylesheet">
<!-- -->
<style>.container {
padding-top: 2em;
}</style>
</head>
<body>
<div class="container">
<form class="form-horizontal" role="form">
<div class="form-group">
<label for="basic" class="col-lg-2 control-label">"Basic"</label>
<div class="col-lg-10">
<select id="basic" class="selectpicker show-tick form-control" data-live-search="true">
<option>cow</option>
<option>bull</option>
<option class="get-class" disabled>ox</option>
<optgroup label="test" data-subtext="another test" data-icon="icon-ok">
<option>ASD</option>
<option selected>Bla</option>
<option>Ble</option>
</optgroup>
</select>
</div>
</div>
</form>
<hr>
<form class="form-horizontal" role="form">
<div class="form-group">
<label for="basic2" class="col-lg-2 control-label">"Basic" #2 (multiple max-option=1)</label>
<div class="col-lg-10">
<select id="basic2" class="selectpicker show-tick form-control" data-live-search="true" multiple data-max-options="1">
<option>cow</option>
<option>bull</option>
<option class="get-class" disabled>ox</option>
<optgroup label="test" data-subtext="another test" data-icon="icon-ok">
<option>ASD</option>
<option selected>Bla</option>
<option>Ble</option>
</optgroup>
</select>
</div>
</div>
</form>
<hr>
<form class="form-horizontal" role="form">
<div class="form-group">
<label for="maxOption2" class="col-lg-2 control-label">multiple, show-menu-arrow, & max-option = 2</label>
<div class="col-lg-10">
<select id="maxOption2" class="selectpicker show-menu-arrow form-control" multiple data-max-options="2">
<option>cow</option>
<option>bull</option>
<option class="get-class" disabled>ox</option>
<optgroup label="test" data-subtext="another test" data-icon="icon-ok">
<option>ASD</option>
<option selected>Bla</option>
<option>Ble</option>
</optgroup>
</select>
</div>
</div>
</form>
<hr>
<form class="form-inline">
<div class="form-group">
<label class="col-md-1 control-label" for="lunch">Lunch: </label>
</div>
<div class="form-group">
<select id="lunch" class="selectpicker" data-live-search="true" title="Please select a lunch ...">
<option>Hot Dog, Fries and a Soda</option>
<option>Burger, Shake and a Smile</option>
<option>Sugar, Spice and all things nice</option>
<option>Baby Back Ribs</option>
<option>A really really long option made to illustrate an issue with the live search in an inline form</option>
</select>
</div>
</form>
<hr>
<form class="form-horizontal" role="form">
<div class="form-group">
<label for="error" class="col-lg-2 control-label">error</label>
<div class="col-lg-10 error">
<select id="error" class="selectpicker show-tick form-control">
<option>cow</option>
<option>bull</option>
<option class="get-class" disabled>ox</option>
<optgroup label="test" data-subtext="another test" data-icon="icon-ok">
<option>ASD</option>
<option selected>Bla</option>
<option>Ble</option>
</optgroup>
</select>
</div>
</div>
</form>
</div>
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js"></script>
<script type="text/javascript" src="dist/js/bootstrap-select.js"></script>
<!-- 3.2 -->
<script src="//netdna.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
<!-- -->
<!-- 2.3.2 ->
<script src="//netdna.bootstrapcdn.com/twitter-bootstrap/2.3.2/js/bootstrap.js"></script>
<!-- -->
<script type="text/javascript">
$(window).on('load', function () {
$('.selectpicker').selectpicker();
});
</script>
</body>
</html>