forked from dtouzeau/artica-1.5
-
Notifications
You must be signed in to change notification settings - Fork 0
/
miniadm.toolbox.php
52 lines (35 loc) · 1.38 KB
/
miniadm.toolbox.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
<?php
include_once(dirname(__FILE__)."/ressources/class.mini.admin.inc");
include_once(dirname(__FILE__)."/ressources/class.templates.inc");
include_once(dirname(__FILE__)."/ressources/class.user.inc");
include_once(dirname(__FILE__)."/ressources/class.langages.inc");
if(isset($_GET["script"])){echo toolbox();}
function toolbox(){
$array[$_SESSION["uid"]]="RefreshCenterPanel()";
if($_GET["script"]=="miniadm.www.services.php"){
$title="myWebServices";
$array["{myWebServices}"]="Loadjs('miniadm.www.services.php')";
}
if($_GET["script"]=="center-panel"){
$array["{home}"]="RefreshCenterPanel()";
}
if($_GET["script"]=="miniamd.user.rtmm.php"){
$array["{postfix_realtime_events_text}"]="LoadAjax('BodyContent','miniamd.user.rtmm.php')";
}
if($_GET["script"]=="miniadm.openvpn.client.php"){
$array["{my_vpn_cnx}"]="LoadAjax('BodyContent','miniadm.openvpn.client.php')";
}
if($_GET["script"]=="my.addressbook.php"){
$array["{my_address_book}"]="LoadAjax('BodyContent','my.addressbook.php')";
}
compiletool($array);
}
function compiletool($array){
$spacer=" » ";
$stylehref="style='font-size:12px;text-decoration:underline'";
while (list ($num, $val) = each ($array) ){
$f[]="<a href=\"javascript:blur();\" OnClick=\"javascript:$val\" $stylehref>$num</a>$spacer";
}
$tpl=new templates();
echo $tpl->_ENGINE_parse_body(@implode("",$f));
}