Alternc
3.2
Alternc logiel libre pour l'hébergement
Main Page
Related Pages
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Pages
bro_pref.php
Go to the documentation of this file.
1
<?php
2
/*
3
$Id: bro_pref.php,v 1.2 2003/06/10 06:45:16 root Exp $
4
----------------------------------------------------------------------
5
AlternC - Web Hosting System
6
Copyright (C) 2002 by the AlternC Development Team.
7
http://alternc.org/
8
----------------------------------------------------------------------
9
Based on:
10
Valentin Lacambre's web hosting softwares: http://altern.org/
11
----------------------------------------------------------------------
12
LICENSE
13
14
This program is free software; you can redistribute it and/or
15
modify it under the terms of the GNU General Public License (GPL)
16
as published by the Free Software Foundation; either version 2
17
of the License, or (at your option) any later version.
18
19
This program is distributed in the hope that it will be useful,
20
but WITHOUT ANY WARRANTY; without even the implied warranty of
21
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22
GNU General Public License for more details.
23
24
To read the license please visit http://www.gnu.org/copyleft/gpl.html
25
----------------------------------------------------------------------
26
Original Author of file: Benjamin Sonntag
27
Purpose of file: Configuration of the file browser
28
----------------------------------------------------------------------
29
*/
30
require_once(
"../class/config.php"
);
31
32
$fields
= array (
33
"submit"
=> array (
"post"
,
"string"
,
""
),
34
"editsizex"
=> array (
"post"
,
"string"
,
""
),
35
"listmode"
=> array (
"post"
,
"string"
,
""
),
36
"editsizey"
=> array (
"post"
,
"string"
,
""
),
37
"showicons"
=> array (
"post"
,
"string"
,
""
),
38
"downfmt"
=> array (
"post"
,
"string"
,
""
),
39
"createfile"
=> array (
"post"
,
"string"
,
""
),
40
"showtype"
=> array (
"post"
,
"string"
,
""
),
41
"editor_font"
=> array (
"post"
,
"string"
,
""
),
42
"editor_size"
=> array (
"post"
,
"string"
,
""
),
43
"golastdir"
=> array (
"post"
,
"string"
,
""
),
44
);
45
getFields
(
$fields
);
46
47
if
(!empty($submit)) {
48
$bro->SetPrefs($editsizex, $editsizey, $listmode, $showicons, $downfmt, $createfile, $showtype, $editor_font, $editor_size, $golastdir);
49
$error
=_(
"Your preferences have been updated."
);
50
include(
"bro_main.php"
);
51
exit
;
52
}
53
$p
=$bro->GetPrefs();
54
55
include_once(
"head.php"
);
56
57
?>
58
<?php
if
(
isset
(
$error
) &&
$error
) echo
"<font color=\"red\">$error</font><br />"
; ?>
59
<h3><?php
__
(
"File browser preferences"
); ?></h3>
60
<hr
id
=
"topbar"
/>
61
<br />
62
<form action=
"bro_pref.php"
method=
"post"
>
63
64
65
<table cellpadding=
"6"
border=
"1"
cellspacing=
"0"
class
=
'tedit'
>
66
<tr><th><?php
__
(
"Horizontal window size"
); ?></th><td><select
class
=
"inl"
name=
"editsizex"
>
67
<?php
68
for
(
$i
=50;
$i
<=200;
$i
+=10) {
69
echo
"<option"
;
70
if
(
$p
[
"editsizex"
]==
$i
) echo
" selected='selected'"
;
71
echo
">$i</option>"
;
72
}
73
?></select></td></tr>
74
<tr><th><?php
__
(
"Vertical window size"
); ?></th><td><select
class
=
"inl"
name=
"editsizey"
>
75
<?php
76
for
(
$i
=4;
$i
<=80;
$i
+=2) {
77
echo
"<option"
;
78
if
(
$p
[
"editsizey"
]==
$i
) echo
" selected='selected'"
;
79
echo
">$i</option>"
;
80
}
81
?></select></td></tr>
82
<tr><th><?php
__
(
"File editor font name"
); ?></th><td><select
class
=
"inl"
name=
"editor_font"
>
83
<?php
84
for
(
$i
=0;
$i
<count($bro->l_editor_font);
$i
++) {
85
echo
"<option"
;
86
if
(
$p
[
"editor_font"
]==$bro->l_editor_font[
$i
]) echo
" selected='selected'"
;
87
echo
">"
._($bro->l_editor_font[
$i
]).
"</option>"
;
88
}
89
?></select></td></tr>
90
<tr><th><?php
__
(
"File editor font size"
); ?></th><td><select
class
=
"inl"
name=
"editor_size"
>
91
<?php
92
for
(
$i
=0;
$i
<count($bro->l_editor_size);
$i
++) {
93
echo
"<option"
;
94
if
(
$p
[
"editor_size"
]==$bro->l_editor_size[
$i
]) echo
" selected='selected'"
;
95
echo
">"
._($bro->l_editor_size[
$i
]).
"</option>"
;
96
}
97
?></select></td></tr>
98
<tr><th><?php
__
(
"File list view"
); ?></th><td><select
class
=
"inl"
name=
"listmode"
>
99
<?php
100
for
(
$i
=0;
$i
<count($bro->l_mode);
$i
++) {
101
echo
"<option"
;
102
if
(
$p
[
"listmode"
]==
$i
) echo
" selected='selected'"
;
103
echo
" value=\"$i\">"
._($bro->l_mode[
$i
]).
"</option>"
;
104
}
105
?></select></td></tr>
106
<tr><th><?php
__
(
"Downloading file format"
); ?></th><td><select
class
=
"inl"
name=
"downfmt"
>
107
<?php
108
for
(
$i
=0;
$i
<count($bro->l_tgz);
$i
++) {
109
echo
"<option"
;
110
if
(
$p
[
"downfmt"
]==
$i
) echo
" selected='selected'"
;
111
echo
" value=\"$i\">"
._($bro->l_tgz[
$i
]).
"</option>"
;
112
}
113
?></select></td></tr>
114
<tr><th><?php
__
(
"What to do after creating a file"
); ?></th><td><select
class
=
"inl"
name=
"createfile"
>
115
<?php
116
for
(
$i
=0;
$i
<count($bro->l_createfile);
$i
++) {
117
echo
"<option"
;
118
if
(
$p
[
"createfile"
]==
$i
) echo
" selected='selected'"
;
119
echo
" value=\"$i\">"
._($bro->l_createfile[
$i
]).
"</option>"
;
120
}
121
?></select></td></tr>
122
<tr><th><?php
__
(
"Show icons?"
); ?></th><td><select
class
=
"inl"
name=
"showicons"
>
123
<?php
124
for
(
$i
=0;
$i
<count($bro->l_icons);
$i
++) {
125
echo
"<option"
;
126
if
(
$p
[
"showicons"
]==
$i
) echo
" selected='selected'"
;
127
echo
" value=\"$i\">"
._($bro->l_icons[
$i
]).
"</option>"
;
128
}
129
?></select></td></tr>
130
<tr><th><?php
__
(
"Show file types?"
); ?></th><td><select
class
=
"inl"
name=
"showtype"
>
131
<?php
132
for
(
$i
=0;
$i
<count($bro->l_icons);
$i
++) {
133
echo
"<option"
;
134
if
(
$p
[
"showtype"
]==
$i
) echo
" selected='selected'"
;
135
echo
" value=\"$i\">"
._($bro->l_icons[
$i
]).
"</option>"
;
136
}
137
?></select></td></tr>
138
<tr><th><?php
__
(
"Remember last visited directory?"
); ?></th><td><select
class
=
"inl"
name=
"golastdir"
>
139
<?php
140
for
(
$i
=0;
$i
<count($bro->l_icons);
$i
++) {
141
echo
"<option"
;
142
if
(
$p
[
"golastdir"
]==
$i
) echo
" selected='selected'"
;
143
echo
" value=\"$i\">"
._($bro->l_icons[
$i
]).
"</option>"
;
144
}
145
?></select></td></tr>
146
</table>
147
<br/>
148
149
<input type=
"submit"
name=
"submit"
class
=
"inb"
value=
"<?php __("
Change my settings
"); ?>"
/>
150
<input type=
"button"
class
=
"inb"
name=
"cancel"
value=
"<?php __("
Cancel
"); ?>"
onclick=
"document.location='bro_main.php'"
/>
151
152
153
</form>
154
<?php include_once(
"foot.php"
); ?>
code
alternc
bureau
admin
bro_pref.php
Generated on Mon Mar 24 2014 17:14:20 for Alternc by
1.8.1.2