-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathviewProjects.php
More file actions
76 lines (63 loc) · 1.69 KB
/
viewProjects.php
File metadata and controls
76 lines (63 loc) · 1.69 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
<?php
session_start();
include './Template.php';
include './DBConfig.php';
$mysql = new DBConfig();
$db = $mysql->getDBConfig();
$head = '<link rel="stylesheet" href="//code.jquery.com/ui/1.10.4/themes/smoothness/jquery-ui.css">
<script src="//code.jquery.com/ui/1.10.4/jquery-ui.js"></script>';
$header = new Template("./header.php", array('head' => $head, 'title' => "View Projects",'return'=>"viewProjects.php",'current_page'=>2));
$header->out();
?>
<!-- content-wrap -->
<div id="content-wrap">
<!-- content -->
<div id="content" class="clearfix">
<!-- main -->
<div id="main">
<div class="main-content">
<form action= "updateProject.php" method= "post">
<table class="view">
<tr><td class="bold"> Project ID</td>
<td class="bold">Project Name</td>
<td class="bold">Project Status</td>
</tr>
<?php
$query= "SELECT uid, name, status FROM project WHERE deleted='N' ORDER BY uid";
$result= $db->query($query);
if(mysqli_num_rows($result) != 0)
{
while($row= mysqli_fetch_row($result))
{
$id = $row[0];
$n = $row[1];
echo'<tr><td>';
echo "<input type='radio' name='radio' value= '$id' > " ;
echo " ". $id . " </td><td>" . $n. "</td><td>" . $row[2];
echo '</td></tr>';
}
?>
</table><table>
<tr>
<td><input type="submit" class="btn btn-info" value="Select Project" name="submit"></td>
</tr></table>
<?php
}
else
echo "<tr>You have no projects</tr>";
?>
</tbody>
</table></form>
</div>
<!-- /main -->
</div>
<!-- sidebar -->
<? include './sidebar.php'; ?>
<!-- content -->
</div>
<!-- /content-out -->
</div>
<!-- extra -->
<?php
include './footer.php';
?>