Subversion Repositories ALCASAR

Rev

Rev 3254 | Details | Compare with Previous | Last modification | View Log

Rev Author Line No. Line
324 richard 1
<?php
911 richard 2
//gestion de la langue
3
if (is_file("../lib/langues.php"))
4
	include("../lib/langues.php");
324 richard 5
require('/etc/freeradius-web/config.php');
6
 
7
if (is_file("../lib/sql/drivers/$config[sql_type]/functions.php"))
8
	include_once("../lib/sql/drivers/$config[sql_type]/functions.php");
9
else{
10
	echo <<<EOM
911 richard 11
<html>
12
<title>Find group</title>
1805 clement.si 13
<meta http-equiv="Content-Type" content="text/html" charset="$config[general_charset]">
2817 rexy 14
<link rel="stylesheet" href="/css/acc.css">
324 richard 15
</head>
16
<body>
17
<center>
18
<b>Could not include SQL library functions. Aborting</b>
19
</body>
20
</html>
21
EOM;
22
	exit();
23
}
1805 clement.si 24
if ($config['general_lib_type'] != 'sql'){
324 richard 25
	echo <<<EOM
911 richard 26
<html>
27
<title>find group</title>
1860 raphael.pi 28
<meta http-equiv="Content-Type" content="text/html" charset="$config[general_charset]">
2875 rexy 29
<link rel="stylesheet" href="/css/acc.css">
324 richard 30
</head>
31
<body>
32
<center>
33
<b>This page is only available if you are using sql as general library type</b>
34
</body>
35
</html>
36
EOM;
37
	exit();
38
}
39
?>
3254 rexy 40
<html>
324 richard 41
<head>
3264 rexy 42
	<title>Find group</title>
43
	<meta http-equiv="Content-Type" content="text/html; charset=<?php echo $config['general_charset']?>">
44
	<link rel="stylesheet" href="/css/acc.css">
45
	<link rel="stylesheet" href="/css/jquery.dataTables.css">
46
	<script src="/js/jquery-3.6.min.js"></script>
47
	<script src="/js/jquery.dataTables.js"></script>
48
	<script type="text/javascript">
49
		$(document).ready(function() {
50
			$('#datatable_display').DataTable();
51
		});
52
		$.extend(true, $.fn.dataTable.defaults, {
53
			language: {url: '/js/jquery.dataTables.<?= $Language ?>.json'},
54
			columns: [{ type: 'html-num' }, null, { type: 'html-num' }],
55
		});
56
	</script>
324 richard 57
</head>
58
<body>
3254 rexy 59
<table width="100%" border="0" cellspacing="0" cellpadding="0">
911 richard 60
	<tr><th><?php echo "$l_groups_managment"; ?></th></tr>
1805 clement.si 61
	<tr bgcolor="#FFCC66"><td><img src="/images/pix.gif" width="1"
324 richard 62
height="2"></td></tr>
3254 rexy 63
</table>
64
<table width="100%" border=0 cellspacing=0 cellpadding=1>
324 richard 65
	<tr bgcolor="#666666"><td>
3254 rexy 66
	<table width="100%" border=0 cellspacing=0 cellpadding=2>
324 richard 67
		<tr><td valign="middle" align="left">
68
<center>
69
<table border=0 width=540 cellpadding=1 cellspacing=1>
70
<tr valign=top>
71
<td width=55%></td>
72
<td bgcolor="black" width=45%>
73
	<table border=0 width=100% cellpadding=2 cellspacing=0>
74
	<tr bgcolor="#907030" align=right valign=top><th>
911 richard 75
	<font color="white"><?php echo "$l_group_select"; ?></font>
324 richard 76
	</th></tr>
77
	</table>
78
</td></tr>
79
<tr bgcolor="black" valign=top><td colspan=2>
80
	<table border=0 width=100% cellpadding=12 cellspacing=0 bgcolor="#ffffd0" valign=top>
81
	<tr><td>
82
<?php
83
unset($login);
84
$num = 0;
85
include_once("../lib/$config[general_lib_type]/group_info.php");
86
if (isset($existing_groups)){
3254 rexy 87
	echo "<table border=1 id=\"datatable_display\" class=\"display\" bordercolordark=#ffffe0 bordercolorlight=#000000 width=100% cellpadding=2 cellspacing=0 bgcolor=\"#ffffe0\" valign=top>";
88
	echo "<thead>";
89
	echo "<tr bgcolor=\"#686464\">";
324 richard 90
	echo "<th>#</th><th>$l_group </th><th>$l_nb_users</th></tr>";
3254 rexy 91
	echo "</thead>";
92
	echo "<tbody>";
324 richard 93
	foreach ($existing_groups as $group => $num_members){
94
		$num++;
95
		$Group = urlencode($group);
96
		echo <<<EOM
97
		<tr align=center>
98
			<td>$num</td>
99
			<td><a href="group_admin.php?login=$Group" title="Editer le groupe $group">$group</a></td>
100
			<td>$num_members</td>
101
		</tr>
102
EOM;
103
	}
3254 rexy 104
	echo "</tbody>";
324 richard 105
}
106
else
912 richard 107
	echo "<b>$l_group_empty</b>\n";
324 richard 108
?>
109
	</table>
110
</table>
3254 rexy 111
</td></tr>
112
</table>
324 richard 113
</tr>
114
</table>
115
</td></tr>
3254 rexy 116
</table>
324 richard 117
</body>
118
</html>