-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathproject.php
79 lines (70 loc) · 3.57 KB
/
project.php
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
<?php
require_once 'header.php';
?>
<body>
<div class="projectPage">
<div class="container-fluid">
<div class="row" id="aboutUs">
<div class="col-sm-7 col-sm-offset-1">
<p class="projectsAvailableTag">PROJECTS AVAILABLE</p>
<!-- <p class="text-justify"><strong>The following projects are available to work upon as summer intern during summer vacations, 2018 </strong></p> -->
</div>
<div class="col-sm-3">
<input class="form-control projectSearchingInput" id="myInput" type="text" placeholder="Search Projects..">
</div>
</div>
<div class="row" id="objectives">
<div class="container projectTableDiv">
<table class="table table-hover">
<?php
$sql = "SELECT sparkId,name,department,project from faculty where role='faculty' order by department";
$result = $conn->query($sql);
if($result) {
if($result->num_rows == 0) {
echo '<p>There are no entries in the database</p>';
}
else {
echo '<thead style="">
<tr>
<th style="width:13%">ID</th>
<th style="width:13%">Name</th>
<th style="width:13%">Department</th>
<th style="width:61%">Research interests/Tentative projects for summer internship</th>
</tr>
</thead>';
while($row = $result->fetch_assoc()) {
echo "
<tbody id='myTable'>
<tr>
<td>{$row['sparkId']}</td>
<td>{$row['name']}</td>
<td>{$row['department']}</td>
<td style='list-style-type:none'>{$row['project']}</td>
<td></td>
</tr>
<div id='spriority1Div'></div>
</tbody>
";
}
}
$result->free();
} ?>
</table>
</div>
</div>
</div>
</div>
<?php include 'footer.php' ; ?>
<?php require_once('login_modal.php'); ?>
<script>
$(document).ready(function(){
$("#myInput").on("keyup", function() {
var value = $(this).val().toLowerCase();
$("#myTable tr").filter(function() {
$(this).toggle($(this).text().toLowerCase().indexOf(value) > -1)
});
});
});
</script>
<!--http://www.convertcsv.com/csv-to-html.htm-->
</body>