-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTask.html
More file actions
179 lines (154 loc) · 5.21 KB
/
Task.html
File metadata and controls
179 lines (154 loc) · 5.21 KB
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
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
<!DOCTYPE html>
<html>
<head>
<title>Crud Task</title>
<link rel="stylesheet" href="style.css">
<link rel="icon" type="image/x-icon" href="/4750856-200.png ">
<!-- font-awesome -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<!-- font family -->
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
href="https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;1,100;1,200&display=swap"
rel="stylesheet"
/>
</head>
<body>
<h1 id="work"></h1>
<h2> Employee Form </h2>
<div class ="diameter">
<h4> Add Employee </h4>
<div class="container">
<form id="employeeForm" autocomplete="on">
<!-- ----- Name ---- -->
<div class="row">
<div class="col-25">
<label for="name">Name * :</label>
</div>
<div class="col-75">
<input type="text" id="name" name="name" placeholder="Your Name.." minlength="4" maxlength="20" >
<span class="err-message" id="name-error"></span>
</div>
</div>
<br />
<!-- ----- Gender ---- -->
<div class="row">
<div class="col-25">
<label>Gender * :</label>
</div>
<div class="col-75">
<input type="radio" id="male" name="gender" value="Male" checked> Male
<input type="radio" id="female" name="gender" value="Female"> Female
<span class="err-message" id="gender-error"></span>
</div>
</div>
<br />
<!-- ----- DOB ---- -->
<div class="row">
<div class="col-25">
<label for="dob">Date of Birth * :</label>
</div>
<div class="col-75">
<input type="date" id="dob" name="dob" placeholder="Your birth-date.."
onfocus="this.max=new Date().toISOString().split('T')[0]" >
<span class="err-message" id="dob-error"></span>
</div>
</div>
<br />
<!-- ----- Email-ID ---- -->
<div class="row">
<div class="col-25">
<label for="email">Email * :</label>
</div>
<div class="col-75">
<input type="email" id="email" name="email" placeholder="Your Email.." >
<span class="err-message" id="email-error"></span>
</div>
</div>
<br />
<!-- ----- Phone Number ---- -->
<div class="row">
<div class="col-25">
<label for="phone">Phone Number :</label>
</div>
<div class="col-75">
<input type="tel" id="phone" name="phone" placeholder="Your Phone Number.." pattern="[0-9]{10}"
maxlength="10">
<span class="err-message" id="phone-error"></span>
</div>
</div>
<br />
<!-- ----- Hobbies ---- -->
<div class="row">
<div class="col-25">
<label for="hobbies">Hobbies :</label>
</div>
<div class="col-75">
<input type="checkbox" value="Cricket" id="hobby1" class="txtcricket" name="hobby"> Cricket <br />
<input type="checkbox" value="Chess" id="hobby2" class="txtchess" name="hobby"> Chess <br />
<input type="checkbox" value="Music" id="hobby3" class="txtmusic" name="hobby"> Music <br />
</div>
</div>
<br />
<!-- ----- Button ---- -->
<div class="row" style="margin-left: 24%;">
<input type="submit" value="Submit" id="submitButton" onclick="handleEmployee();return false">
<input type="button" value="Cancel" id="cancelButton" style="display: none;">
</div>
</form>
</div>
</div>
<br />
<!-- ----- Basic Table ---- -->
<h2> Display </h2>
<div class ="diameter">
<h4> Display </h4>
<div class="container">
<table id="employeeTable" border="1">
<tr>
<th>Name</th>
<th>Gender</th>
<th>Date of Birth</th>
<th>Email</th>
<th>Phone</th>
<th>Hobbies</th>
<th>Action</th>
</tr>
</table>
</div>
</div>
<br />
<!-- <h2> Advanced </h2> -->
<div class ="diameter" style="display: none;">
<h4> Display </h4>
<div class="container">
<table id="advancedTable" border="1">
<tr id="nameField">
<th>Name</th>
</tr>
<tr id="genderField">
<th>Gender</th>
</tr>
<tr id="DOBField">
<th>DOB</th>
</tr>
<tr id="EmailField">
<th>Email</th>
</tr>
<tr id="PhoneField">
<th>Phone</th>
</tr>
<tr id="HobbyField">
<th>Hobbies</th>
</tr>
<tr id="ActionField">
<th>Action</th>
</tr>
</table>
</div>
</div>
<script type="text/javascript" src="validation.js"></script>
<script type="text/javascript" src="script.js"></script>
</body>
</html>