-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.php
More file actions
executable file
·78 lines (69 loc) · 2.6 KB
/
index.php
File metadata and controls
executable file
·78 lines (69 loc) · 2.6 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
<?php
require 'employee.php';
$emp = new Emp;
$employees= $emp-> employees();
?>
<!DOCTYPE html>
<html>
<head>
<title>mindset task..</title>
<link rel="stylesheet" type="text/css" href="css/bootstrap.css">
<link rel="stylesheet" href="css/remodal.css" />
<link rel="stylesheet" href="css/remodal-default-theme.css" />
</head>
<body>
<div class="container">
<div class="table-responsive">
<table class="table">
<thead>
<tr>
<td>Name</td>
<td>Email</td>
<td>Salary</td>
</tr>
</thead>
<tbody>
<?php
foreach ($employees as $key=>$value) {
foreach ($value as $key1 =>$item) {
if($key1!='id')
echo "<td>{$item}</td>";
}
echo '<td><a data-remodal-target="update_up"><span class="glyphicon glyphicon-pencil getdata" id="'.$value['id'].'" aria-hidden="true"></span></a></td>';
echo '<td><a><span class="glyphicon glyphicon-remove delete" id="'.$value['id'].'" aria-hidden="true"></span></a></td>';
echo '</tr>';
}
?>
</tbody>
</table>
</div>
<div class="remodal pin-code-modal" data-remodal-id="update_up">
<button data-remodal-action="close" class="glyphicon glyphicon-remove"></button>
<form class="form-inline" id="collapseOne">
<div class="form-group">
<input type="text" class="form-control" id="up_name" placeholder="Name">
<input type="email" class="form-control" id="up_email" placeholder="email@example.com">
<input type="number" class="form-control" id='up_sal' placeholder="Salary">
</div>
<button type="submit" class="btn btn-primary" data-remodal-action="close" id="update" value="">Update</button>
</form>
</div>
<a data-remodal-target="verify">insert new employee</a>
<div class="remodal pin-code-modal" data-remodal-id="verify">
<button data-remodal-action="close" class="glyphicon glyphicon-remove"></button>
<form class="form-inline" id="collapseOne">
<div class="form-group">
<input type="text" class="form-control" id="name" placeholder="Name">
<input type="email" class="form-control" id="email" placeholder="email@example.com">
<input type="number" class="form-control" id='sal' placeholder="Salary">
</div>
<button type="submit" class="btn btn-primary" data-remodal-action="close" id="add">Insert</button>
</form>
</div>
</div>
<script src="js/jquery.min.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src="js/remodal.js"></script>
<script src="js/main.js" type="text/javascript" ></script>
</body>
</html>