-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathinput_tag.html
More file actions
29 lines (29 loc) · 927 Bytes
/
input_tag.html
File metadata and controls
29 lines (29 loc) · 927 Bytes
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
<html>
<head>
<title>input-tag demo</title>
<link rel="stylesheet" type="text/css" href="css/input_tag.css">
<meta charset="utf8">
</head>
<body>
<div class="input-tag" data-init="this,is,interesting"><!-- one way to init some tags -->
<input type="text" class="input-text">
<div class="width-helper"></div>
<input class="input-field" type="hidden" name="tag" value="">
</div>
<script type="text/javascript" src="js/jquery.min.js"></script>
<script type="text/javascript" src="js/input_tag.js"></script>
<script type="text/javascript">
$(function(){
//init the input-tag plugin
/* another way to init some tags, this will overwrite the first way */
tag = $('.input-tag').inputtag({
'data_init' : 'init,with,something',
'max_tag_count' : 3,
'on_max_tag_count' : function(){
console.warn('reach the limitation of tag count');
}
});
});
</script>
</body>
</html>