-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathperm_desc.php
More file actions
63 lines (46 loc) · 884 Bytes
/
perm_desc.php
File metadata and controls
63 lines (46 loc) · 884 Bytes
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
<?php
include('inc/getperms.php');
include('inc/functions.php');
if($highest_perm < 3) {
print_error(array("You don't have permission to be here"));
die;
}
/* get perms info */
$perms_info = array();
$perm_sql = ""
. "SELECT *"
. " FROM permission_desc"
. " ORDER BY perm_level DESC"
;
$perm_res = mysql_query($perm_sql);
if(!$perm_res) {
die("Database error (permissions info): " . mysql_error());
}
print <<<START
<html>
<head>
<link rel="stylesheet" type="text/css" href="style/main.css"/>
<title>GSW Faculty Evaluations</title>
</head>
<body>
<div id='content'>
START;
while($row = mysql_fetch_assoc($perm_res)) {
$plvl = $row['perm_level'];
$pname = $row['perm_name'];
$pdesc = $row['perm_desc'];
$pdesc = nl2br($pdesc);
print <<<DESC
<h2>$pname</h2>
<h3>permission level $plvl</h3>
<p>
$pdesc
</p>
DESC;
}
print <<<END
</div>
</body>
</html>
END;
?>