-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathadmin_log.php
61 lines (38 loc) · 1.25 KB
/
admin_log.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
<?php
// Userspice
require_once 'users/init.php';
require_once $abs_us_root.$us_url_root.'users/includes/template/prep.php';
if (!securePage($_SERVER['PHP_SELF']))
die();
if (!$user->isLoggedIn())
Redirect::to('users\login.php');
$uid = $user->data()->id;
require_once "common.php";
$gs_my_permission_level = GS_get_permission_level($user);
if ($gs_my_permission_level != GS_PERM_ADMIN)
Redirect::to('index.php');
?>
<DIV ID="page-wrapper">
<DIV CLASS="container">
<?php
echo "<table style=\"width:100%\"><tr>";
foreach(["id","date","description"] as $cell)
echo "<th>".ucfirst($cell)."</th>";
echo "</tr>";
$table = GS_get_activity_log(600, [GS_LOG_SERVER_MOD_CHANGED], true, $gs_permission_level);
foreach($table as $row) {
echo "<tr>
<td>{$row["id"]}</td>
<td>".date("D, d M Y H:i:s", $row["date"])."</td>
<td>{$row["description"]}</td>
</tr>";
}
echo "</table>";
echo "<br><br>";
if (isset($user) && $user->isLoggedIn())
languageSwitcher();
?>
</DIV> <!-- /.container -->
</DIV> <!-- /.wrapper -->
<!-- Place any per-page javascript here -->
<?php require_once $abs_us_root . $us_url_root . 'usersc/templates/' . $settings->template . '/footer.php'; //custom template footer ?>