1 <!DOCTYPE HTML
PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
4 <title
>aMule control panel
</title
>
5 <meta http
-equiv
="Content-Type" content
="text/html; charset=UTF-8">
7 <script language
="JavaScript" type
="text/JavaScript">
9 function MM_swapImgRestore() { //v3.0
10 var i
,x
,a
=document
.MM_sr
; for(i
=0;a
&&i
<a
.length
&&(x
=a
[i
])&&x
.oSrc
;i++
) x
.src
=x
.oSrc
;
13 function MM_preloadImages() { //v3.0
14 var d
=document
; if(d
.images
){ if(!d
.MM_p
) d
.MM_p
=new Array();
15 var i
,j
=d
.MM_p
.length
,a
=MM_preloadImages
.arguments
; for(i
=0; i
<a
.length
; i++
)
16 if (a
[i
].indexOf("#")!=0){ d
.MM_p
[j
]=new Image
; d
.MM_p
[j++
].src
=a
[i
];}}
19 function MM_findObj(n
, d
) { //v4.01
20 var p
,i
,x
; if(!d
) d
=document
; if((p
=n
.indexOf("?"))>0&&parent
.frames
.length
) {
21 d
=parent
.frames
[n
.substring(p+
1)].document
; n
=n
.substring(0,p
);}
22 if(!(x
=d
[n
])&&d
.all
) x
=d
.all
[n
]; for (i
=0;!x
&&i
<d
.forms
.length
;i++
) x
=d
.forms
[i
][n
];
23 for(i
=0;!x
&&d
.layers
&&i
<d
.layers
.length
;i++
) x
=MM_findObj(n
,d
.layers
[i
].document
);
24 if(!x
&& d
.getElementById
) x
=d
.getElementById(n
); return x
;
27 function MM_swapImage() { //v3.0
28 var i
,j
=0,x
,a
=MM_swapImage
.arguments
; document
.MM_sr
=new Array; for(i
=0;i
<(a
.length
-2);i+
=3)
29 if ((x
=MM_findObj(a
[i
]))!=null){document
.MM_sr
[j++
]=x
; if(!x
.oSrc
) x
.oSrc
=x
.src
; x
.src
=a
[i+
2];}
33 <link href
="style.css" rel
="stylesheet" type
="text/css"><style type
="text/css">
36 font
-family
: Helvetica
;
42 font
-family
: Helvetica
;
50 text
-decoration
: none
;
54 text
-decoration
: none
;
58 text
-decoration
: none
;
62 text
-decoration
: underline
;
65 font
-family
: Helvetica
;
70 font
-family
: Helvetica
;
75 font
-family
: Helvetica
;
80 font
-family
:"trebuchet ms",sans
-serif
;
85 border
:1px solid
#003161;
86 background
-color
: white
;
87 font
-family
:"trebuchet ms",sans
-serif
;
92 background
-color
: white
;
97 border
:1px solid
#003161;
98 background
-color
: #90B6DB;
99 font
-family
:"trebuchet ms",sans
-serif
;
105 </head
><script language
="JavaScript" type
="text/JavaScript">
106 function formCommandSubmit(command
)
108 var frm
=document
.forms
.mainform
109 frm
.command
.value
=command
113 var initvals
= new Object;
116 // apply new options before proceeding
117 //var_dump($HTTP_GET_VARS);
118 if ( ($HTTP_GET_VARS["Submit"] == "Apply") && ($_SESSION["guest_login"] == 0) ) {
119 $file_opts = array("check_free_space", "extract_metadata",
120 "ich_en","aich_trust", "preview_prio","save_sources", "resume_same_cat",
121 "min_free_space", "new_files_paused", "alloc_full", "alloc_full_chunks",
122 "new_files_auto_dl_prio", "new_files_auto_ul_prio"
124 $conn_opts = array("max_line_up_cap","max_up_limit",
125 "max_line_down_cap","max_down_limit", "slot_alloc",
126 "tcp_port","udp_dis","max_file_src","max_conn_total","autoconn_en");
127 $webserver_opts = array("use_gzip", "autorefresh_time");
130 foreach ($conn_opts as $i) {
131 $curr_value = $HTTP_GET_VARS[$i];
132 if ( $curr_value == "on") $curr_value = 1;
133 if ( $curr_value == "") $curr_value = 0;
135 $all_opts["connection"][$i] = $curr_value;
137 foreach ($file_opts as $i) {
138 $curr_value = $HTTP_GET_VARS[$i];
139 if ( $curr_value == "on") $curr_value = 1;
140 if ( $curr_value == "") $curr_value = 0;
142 $all_opts["files"][$i] = $curr_value;
144 foreach ($webserver_opts as $i) {
145 $curr_value = $HTTP_GET_VARS[$i];
146 if ( $curr_value == "on") $curr_value = 1;
147 if ( $curr_value == "") $curr_value = 0;
149 $all_opts["webserver"][$i] = $curr_value;
151 //var_dump($all_opts);
152 amule_set_options($all_opts);
154 $opts = amule_get_options();
156 $opt_groups = array("connection", "files", "webserver");
157 //var_dump($opt_groups);
158 foreach ($opt_groups as $group) {
159 $curr_opts = $opts[$group];
160 //var_dump($curr_opts);
161 foreach ($curr_opts as $opt_name => $opt_val) {
162 echo 'initvals["', $opt_name, '"] = "', $opt_val, '";';
167 <!-- Assign php generated data to controls
-->
170 var frm
= document
.forms
.mainform
172 var str_param_names
= new Array(
173 "max_line_down_cap", "max_line_up_cap",
174 "max_up_limit", "max_down_limit", "max_file_src",
175 "slot_alloc", "max_conn_total",
176 "tcp_port", "udp_port",
180 for(i
= 0; i
< str_param_names
.length
; i++
) {
181 frm
[str_param_names
[i
]].value
= initvals
[str_param_names
[i
]];
183 var check_param_names
= new Array(
184 "autoconn_en", "reconn_en", "udp_dis", "new_files_paused",
185 "aich_trust", "alloc_full", "alloc_full_chunks",
186 "check_free_space", "extract_metadata", "ich_en",
187 "new_files_auto_dl_prio", "new_files_auto_ul_prio",
190 for(i
= 0; i
< check_param_names
.length
; i++
) {
191 frm
[check_param_names
[i
]].checked
= initvals
[check_param_names
[i
]] == "1" ?
true : false;
196 <body background
="images/fond.gif" leftmargin
="0" topmargin
="0" marginwidth
="0" marginheight
="0" onLoad
="MM_preloadImages('images/transf_1.png','images/shared_1.png','images/search_1.png','images/edkserv_1.png','images/sheserv_1.png','images/stats_1.png');init_data();">
197 <table width
="100%" height
="100%" border
="0" cellpadding
="0" cellspacing
="0">
199 <td width
="143" height
="64"><img src
="images/logo.png" width
="143" height
="64"></td
>
200 <td width
="100%" height
="64" align
="right" background
="images/fond_haut.png"> <table border
="0" cellspacing
="0" cellpadding
="0">
202 <td
><a href
="amuleweb-main-dload.php" onMouseOut
="MM_swapImgRestore()" onMouseOver
="MM_swapImage('transfert','','images/transf_1.png',1)"><img src
="images/transf_0.png" alt
="transfert" name
="transfert" width
="52" height
="50" border
="0"></a
></td
>
203 <td
><a href
="amuleweb-main-shared.php" onMouseOut
="MM_swapImgRestore()" onMouseOver
="MM_swapImage('shared','','images/shared_1.png',1)"><img src
="images/shared_0.png" alt
="shared" name
="shared" width
="52" height
="50" border
="0"></a
></td
>
204 <td
><a href
="amuleweb-main-search.php" onMouseOut
="MM_swapImgRestore()" onMouseOver
="MM_swapImage('search','','images/search_1.png',1)"><img src
="images/search_0.png" alt
="search" name
="search" width
="52" height
="50" border
="0"></a
></td
>
205 <td
><a href
="amuleweb-main-servers.php" onMouseOut
="MM_swapImgRestore()" onMouseOver
="MM_swapImage('edkserver','','images/edkserv_1.png',1)"><img src
="images/edkserv_0.png" alt
="edkserver" name
="edkserver" width
="52" height
="50" border
="0"></a
></td
>
206 <td
><a href
="amuleweb-main-kad.php" onMouseOut
="MM_swapImgRestore()" onMouseOver
="MM_swapImage('sheserv','','images/sheserv_1.png',1)"><img src
="images/sheserv_0.png" alt
="sheserv" name
="sheserv" width
="52" height
="50" border
="0"></a
></td
>
207 <td
><a href
="amuleweb-main-stats.php" onMouseOut
="MM_swapImgRestore()" onMouseOver
="MM_swapImage('statistiques','','images/stats_1.png',1)"><img src
="images/stats_0.png" alt
="statistiques" name
="statistiques" width
="52" height
="50" border
="0"></a
></td
>
208 <td
><img src
="images/col.png"></td
>
210 <td width
="190" align
="right" class="texteinv"><a href
="login.php">exit</a
><br
>
211 <a href
="amuleweb-main-log.php">log
&bull
;</a
> <a href
="amuleweb-main-prefs.php">configuration
</a
></td
>
216 <tr align
="center" valign
="top">
217 <td colspan
="2"> <table width
="100%" border
="0" cellspacing
="0" cellpadding
="0">
222 <td width
="24"><img src
="images/tab_top_left.png" width
="24" height
="24"></td
>
223 <td background
="images/tab_top.png"> 
;</td
>
224 <td width
="24"><img src
="images/tab_top_right.png" width
="24" height
="24"></td
>
227 <td width
="24" background
="images/tab_left.png"> 
;</td
>
228 <td bgcolor
="#FFFFFF">
230 <table width
="100%" border
="0" align
="center" cellpadding
="0" cellspacing
="0">
234 <h1 style
="display:inline;">aMule log
</h1
>
235 <a href
="log.php?rstlog=1" target
="logframe" onclick
="return confirm('Do you really want to reset aMule log?')">(Reset log
)</a
><br
>
236 <iframe width
="100%" height
="400" name
="logframe" src
="log.php"></iframe
>
240 <h1 style
="display:inline;">Serverinfo
</h1
>
241 <a href
="log.php?rstsrv=1" target
="srvframe" onclick
="return confirm('Do you really want to reset Serverinfo?')">(Reset Serverinfo
)</a
>
242 <iframe width
="100%" height
="200" name
="srvframe" src
="log.php?show=srv"></iframe
>
248 <td width
="24" background
="images/tab_right.png"> 
;</td
>
251 <td width
="24"><img src
="images/tab_bottom_left.png" width
="24" height
="24"></td
>
252 <td background
="images/tab_bottom.png"> 
;</td
>
253 <td width
="24"><img src
="images/tab_bottom_right.png" width
="24" height
="24"></td
>
259 <td height
="25" colspan
="2"> <table width
="100%" height
="40" border
="0" cellpadding
="0" cellspacing
="0">
260 <tr align
="center" valign
="middle">
261 <td width
="50%"> <iframe name
="stats" src
="footer.php" height
="35" width
="100%" scrolling
="no" frameborder
="0">edklink
</iframe
>
263 <td width
="50%"> <iframe name
="stats" src
="stats.php" height
="35" width
="100%" scrolling
="no" frameborder
="0">connection
</iframe
>