File: group_admin.php3

package info (click to toggle)
freeradius 1.0.2-4sarge3
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 9,792 kB
  • ctags: 6,980
  • sloc: ansic: 52,618; sh: 9,731; php: 5,764; perl: 2,309; makefile: 1,056; sql: 730; python: 159; tcl: 33; sed: 23
file content (128 lines) | stat: -rw-r--r-- 3,719 bytes parent folder | download
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
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
<?php
if ($show == 1 && isset($del_members)){
        header("Location: user_admin.php3?login=$del_members[0]");
        exit;
}
require('../conf/config.php3');
if ($config[general_lib_type] != 'sql'){
	echo <<<EOM
<title>Group Administration Page</title>
<meta http-equiv="Content-Type" content="text/html; charset=$config[general_charset]">
<link rel="stylesheet" href="style.css">
</head>
<body bgcolor="#80a040" background="images/greenlines1.gif" link="black" alink="black">
<center>
<b>This page is only available if you are using sql as general library type</b>
</body>
</html>
EOM;
	exit();
}

if (is_file("../lib/$config[general_lib_type]/group_info.php3")){
	include("../lib/$config[general_lib_type]/group_info.php3");
	if ($group_exists == 'no'){
		echo <<<EOM
<title>Group Administration Page</title>
<meta http-equiv="Content-Type" content="text/html; charset=$config[general_charset]">
<link rel="stylesheet" href="style.css">
</head>
<body bgcolor="#80a040" background="images/greenlines1.gif" link="black" alink="black">
<center>
<form action="group_admin.php3" method=get>
<b>Group Name&nbsp;&nbsp;</b>
<input type="text" size=10 name="login" value="$login">
<b>&nbsp;&nbsp;does not exist</b><br>
<input type=submit class=button value="Show Group">
</body>
</html>
EOM;
                exit();
        }
}
?>

<html>
<head>
<title>Group Administration Page</title>
<meta http-equiv="Content-Type" content="text/html; charset=<?php echo $config[general_charset]?>">
<link rel="stylesheet" href="style.css">
</head>
<body bgcolor="#80a040" background="images/greenlines1.gif" link="black" alink="black">
<center>
<table border=0 width=550 cellpadding=0 cellspacing=0>
<tr valign=top>
<td align=center><img src="images/title2.gif"></td>
</tr>
</table>
<table border=0 width=400 cellpadding=0 cellspacing=2>

<?php
include("../html/group_toolbar.html.php3");
?>

</table>
<br>
<table border=0 width=540 cellpadding=1 cellspacing=1>
<tr valign=top>
<td width=340></td>
<td bgcolor="black" width=200>
	<table border=0 width=100% cellpadding=2 cellspacing=0>
	<tr bgcolor="#907030" align=right valign=top><th>
	<font color="white">Group <?php echo $login ?> Administration</font>&nbsp;
	</th></tr>
	</table>
</td></tr>
<tr bgcolor="black" valign=top><td colspan=2>
	<table border=0 width=100% cellpadding=12 cellspacing=0 bgcolor="#ffffd0" valign=top>
	<tr><td>

<?php
if ($do_changes == 1){
	if (is_file("../lib/$config[general_lib_type]/group_admin.php3"))
		include("../lib/$config[general_lib_type]/group_admin.php3");
	if (is_file("../lib/$config[general_lib_type]/group_info.php3"))
		include("../lib/$config[general_lib_type]/group_info.php3");
}
?>
	
   
   <form method=post>
      <input type=hidden name=login value=<?php echo $login ?>>
      <input type=hidden name=do_changes value=0>
      <input type=hidden name=show value=0>
	<table border=1 bordercolordark=#ffffe0 bordercolorlight=#000000 width=100% cellpadding=2 cellspacing=0 bgcolor="#ffffe0" valign=top>
<tr>
<td align=right bgcolor="#d0ddb0">
Group Members (Check to Delete)
</td>
<td>
<select name=del_members[] multiple size=5> 
<?php
foreach ($group_members as $member){
	echo "<option value=\"$member\">$member\n";
}
?>
</select>
</td>
</tr>
<tr>
<td align=right bgcolor="#d0ddb0">
New Group Member(s)<br>Separate group members<br> by whitespace or newline
</td>
<td>
<textarea name=new_members cols="15" wrap="PHYSICAL" rows=5></textarea>
</td>
</tr>
	</table>
<br>
<input type=submit class=button value="Commit Changes" OnClick="this.form.do_changes.value=1">
<br><br>
<input type=submit class=button value="Administer selected user" OnClick="this.form.show.value=1">
</form>
</td></tr>
</table>
</tr>
</table>
</body>
</html>