/
ia_list.php
104 lines (99 loc) · 2.29 KB
/
ia_list.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
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
<?php
require('include/message.php');
if( $security->runSecurity($permission->admin, $user->username, 1, 1, 1) )
{
echo('
<div class="contentbox">
<div align="center">
<div class="content_back">
<div align="center">
<div class="content_header">
<h3 class="content_box_header">Pending IA Requests</h3>
</div>
</div>
<form action="process.php" method="post">
<input type="hidden" name="cmd" value="approve_ia" />
<table class="minor_header">
<tr>
<td width="5%">
</td>
<td class="minor_header" width="25%">
<h4 class="content_box_minor_header">
Username
</h4>
</td>
<td class="minor_header" width="70%">
<h4 class="content_box_minor_header">
Reason
</h4>
</td>
<td class="minor_header" width="25%">
<h4 class="content_box_minor_header">
Time
</h4>
</td>
</tr>
');
$sql = 'select id
from ia_request
;';
$result = mysql_query($sql);
while( $row = mysql_fetch_array($result) )
{
$request = new Ia($row['id']);
if( !$request->exists )
{
echo('There are no pending Requests.');
}
else
{
echo('
<tr>
<td>
<input type="radio" name="id" value="' . $row['id'] . '" />
</td>
<td>
<a class="members" href="index.php?view=profile&user=' . $request->username . '&ref=ia_list.php">' . $request->username . '</a>
</td>
<td>
<p>' . $request->reason . '</p>
</td>
<td>
' . dateFromTimestamp( $request->time ) . '
</td>
</tr>
');
}
}
echo('
</table>
<br />
<input type="submit" value="Approve Selected" />
<div>' . $form->error("security") . '</div>
<div>' . $_SESSION['event'] . '</div>
</form>
<hr class="cb" />
<br />
<div><a class="return" href="index.php?view=console">Click Here to return to your console</a></div>
</div>
</div>
<div align="center"><div class="content_box_footer"></div></div>
</div>
<br />
<br />
<br />
<br />
<br />
');
unset($_SESSION['success']);
unset($_SESSION['event']);
}
else
{
echo('
<SCRIPT LANGUAGE="JavaScript">
window.location="index.php?view=security_error";
</script>
');
}
?>