-
Notifications
You must be signed in to change notification settings - Fork 45
/
index.html
executable file
·103 lines (86 loc) · 2.72 KB
/
index.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
<!DOCTYPE html>
<html>
<head>
<meta charset='UTF-8'>
<title>Relevant Dropdown</title>
<link rel='stylesheet' href='css/style.css'>
</head>
<body>
<div id="page-wrap">
<h1>Relevant Dropdown</h1>
<h2>A HTML5 datalist polyfill that depends on jQuery and Modernizr.</h2>
<p>Datalist browser support (Dec 2011) is Firefox 4+ and Opera 10.5+ (or therebouts). Maybe IE 10 too. It's reasonable that you'd want WebKit support. So. This.</p>
<p><input type="text" id="search" list="states" placeholder="Find U.S. State"></p>
<datalist id="states">
<option value="Alabama">
<option value="Alaska">
<option value="Arizona">
<option value="Arkansas">
<option value="California">
<option value="Colorado">
<option value="Connecticut">
<option value="Delaware">
<option value="Florida">
<option value="Georgia">
<option value="Hawaii">
<option value="Idaho">
<option value="Illinois">
<option value="Indiana">
<option value="Iowa">
<option value="Kansas">
<option value="Kentucky">
<option value="Louisiana">
<option value="Maine">
<option value="Maryland">
<option value="Massachusetts">
<option value="Michigan">
<option value="Minnesota">
<option value="Mississippi">
<option value="Missouri">
<option value="Montana">
<option value="Nebraska">
<option value="Nevada">
<option value="New Hampshire">
<option value="New Jersey">
<option value="New Mexico">
<option value="New York">
<option value="North Carolina">
<option value="North Dakota">
<option value="Ohio">
<option value="Oklahoma">
<option value="Oregon">
<option value="Pennsylvania">
<option value="Rhode Island">
<option value="South Carolina">
<option value="South Dakota">
<option value="Tennessee">
<option value="Texas">
<option value="Utah">
<option value="Vermont">
<option value="Virginia">
<option value="Washington">
<option value="West Virginia">
<option value="Wisconsin">
<option value="Wyoming">
</datalist>
<p><input type="text" id="name" list="names" placeholder="Look for someone!"></p>
<datalist id="names">
<option value="Baylor Rae'">
<option value="Chris Coyier">
</datalist>
<p><a href="https://github.com/chriscoyier/Relevant-Dropdowns">GitHub</a></p>
</div>
<script src="js/jquery-1.8.2.min.js"></script>
<script src="js/modernizr.custom.95508.js"></script>
<script>
// Safari reports success of list attribute, so doing ghetto detection instead
yepnope({
test : (!Modernizr.input.list || (parseInt($.browser.version) > 400)),
yep : [
'js/jquery.relevant-dropdown.js',
'js/load-fallbacks.js'
]
});
</script>
</body>
</html>