-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathexample.html
More file actions
37 lines (35 loc) · 857 Bytes
/
example.html
File metadata and controls
37 lines (35 loc) · 857 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
30
31
32
33
34
35
36
37
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>jQuery simple clone plugin</title>
</head>
<body>
<form action="#" method="post">
<div>
<div class="simpleClone-clnElem">
<input type="text" name="sample[]" value="">
</div>
</div>
<div class="simpleClone-btnWrap">
<button type="button" class="addBtn">
+ Add
</button>
</div>
</form>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>
<script src="./jquery.simpleClone.min.js"></script>
<script>
(function ($) {
'use strict';
$('.addBtn').simpleClone({
copyValue: false,
cloneLimit: 5
});
})(jQuery);
</script>
</body>
</html>