-
Notifications
You must be signed in to change notification settings - Fork 6
/
demo.html
58 lines (54 loc) · 1.33 KB
/
demo.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
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8">
<title>jQuery.AutoFill Demo</title>
</head>
<body>
<p>
<label>Default Behavior:</label><br />
<input type="text" id="txtName" />
</p>
<p>
<label>Search:</label><br />
<input type="text" id="txtSearch" />
</p>
<p>
<label>Password:</label><br />
<input type="password" id="pwdPassword" />
</p>
<p>
<label>Web site:</label><br />
<input type="text" id="txtWebsite" />
</p>
<p>
<label>Text Area: </label><br />
<textarea id="test-textarea"></textarea>
</p>
<script src="http://www.google.com/jsapi"></script>
<script>
google.load('jquery','1.4.1');
</script>
<script src="jquery.autofill.js"></script>
<script>
$(document).ready(function(){
$('#txtName').autofill();
$('#txtSearch').autofill({
value: 'Search for Keyword(s)'
});
$('#pwdPassword').autofill({
value: 'Password',
defaultTextColor: '#666',
activeTextColor: '#333'
});
$('#txtWebsite').autofill({
value: 'Website',
prePopulate: 'http://'
});
$('#test-textarea').autofill({
value: "test\nwith\n\newlines"
});
});
</script>
</body>
</html>