tbrehm
2012-06-05 b23de0117336ffca990136ad6d1a9122433dc0fc
commit | author | age
8896ab 1 <?php
N 2
3 /*
4     Form Definition
5
6     Tabledefinition
7
8     Datatypes:
9     - INTEGER (Forces the input to Int)
10     - DOUBLE
11     - CURRENCY (Formats the values to currency notation)
12     - VARCHAR (no format check, maxlength: 255)
13     - TEXT (no format check)
14     - DATE (Dateformat, automatic conversion to timestamps)
15
16     Formtype:
17     - TEXT (Textfield)
18     - TEXTAREA (Textarea)
19     - PASSWORD (Password textfield, input is not shown when edited)
20     - SELECT (Select option field)
21     - RADIO
22     - CHECKBOX
23     - CHECKBOXARRAY
24     - FILE
25
26     VALUE:
27     - Wert oder Array
28
29     Hint:
30     The ID field of the database table is not part of the datafield definition.
31     The ID field must be always auto incement (int or bigint).
32
33
34 */
35
36 $form["title"]             = "System Config";
37 $form["description"]     = "";
38 $form["name"]             = "system_config";
39 $form["action"]            = "system_config_edit.php";
40 $form["db_table"]        = "sys_ini";
41 $form["db_table_idx"]    = "sysini_id";
42 $form["db_history"]        = "yes";
43 $form["tab_default"]    = "sites";
44 $form["list_default"]    = "server_list.php";
45 $form["auth"]            = 'yes'; // yes / no
46
47 $form["auth_preset"]["userid"]  = 0; // 0 = id of the user, > 0 id must match with id of current user
48 $form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
49 $form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
50 $form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
51 $form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
52
53 $form["tabs"]['sites'] = array (
54     'title'     => "Sites",
55     'width'     => 70,
56     'template'     => "templates/system_config_sites_edit.htm",
57     'fields'     => array (
58     ##################################
59     # Begin Datatable fields
60     ##################################
61         'dbname_prefix' => array (
62             'datatype'    => 'VARCHAR',
63             'formtype'    => 'TEXT',
64             'validators'    => array (     0 => array (    'type'    => 'REGEX',
65                                                         'regex' => '/^[a-zA-Z0-0\-\_\[\]]{0,50}$/',
66                                                         'errmsg'=> 'dbname_prefix_error_regex'),
67                                         ),
68             'default'    => '',
69             'value'        => '',
70             'width'        => '30',
71             'maxlength'    => '255'
72         ),
73         'dbuser_prefix' => array (
74             'datatype'    => 'VARCHAR',
75             'formtype'    => 'TEXT',
76             'validators'    => array (     0 => array (    'type'    => 'REGEX',
77                                                         'regex' => '/^[a-zA-Z0-0\-\_\[\]]{0,50}$/',
78                                                         'errmsg'=> 'dbuser_prefix_error_regex'),
79                                         ),
80             'default'    => '',
81             'value'        => '',
82             'width'        => '30',
83             'maxlength'    => '255'
84         ),
85         'ftpuser_prefix' => array (
86             'datatype'    => 'VARCHAR',
87             'formtype'    => 'TEXT',
88             'validators'    => array (     0 => array (    'type'    => 'REGEX',
89                                                         'regex' => '/^[a-zA-Z0-0\-\_\[\]]{0,50}$/',
90                                                         'errmsg'=> 'ftpuser_prefix_error_regex'),
91                                         ),
92             'default'    => '',
93             'value'        => '',
94             'width'        => '30',
95             'maxlength'    => '255'
96         ),
97         'shelluser_prefix' => array (
98             'datatype'    => 'VARCHAR',
99             'formtype'    => 'TEXT',
100             'validators'    => array (     0 => array (    'type'    => 'REGEX',
101                                                         'regex' => '/^[a-zA-Z0-0\-\_\[\]]{0,50}$/',
102                                                         'errmsg'=> 'shelluser_prefix_error_regex'),
103                                         ),
104             'default'    => '',
105             'value'        => '',
106             'width'        => '30',
107             'maxlength'    => '255'
108         ),
109         'webdavuser_prefix' => array (
110             'datatype'    => 'VARCHAR',
111             'formtype'    => 'TEXT',
112             'validators'    => array (     0 => array (    'type'    => 'REGEX',
113                                                         'regex' => '/^[a-zA-Z0-0\-\_\[\]]{0,50}$/',
114                                                         'errmsg'=> 'webdavuser_prefix_error_regex'),
115                                         ),
116             'default'    => '',
117             'value'        => '',
118             'width'        => '30',
119             'maxlength'    => '255'
120         ),
121         'dblist_phpmyadmin_link' => array (
122             'datatype'    => 'VARCHAR',
123             'formtype'    => 'CHECKBOX',
124             'default'    => 'n',
125             'value'        => array(0 => 'n',1 => 'y')
126         ),
127         'phpmyadmin_url' => array (
128             'datatype'    => 'VARCHAR',
129             'formtype'    => 'TEXT',
130             'validators'    => array (     0 => array (    'type'    => 'REGEX',
b23de0 131                                                         'regex' => '/^[0-9a-zA-Z\:\/\-\.\[\]]{0,255}$/',
8896ab 132                                                         'errmsg'=> 'phpmyadmin_url_error_regex'),
N 133                                         ),
134             'default'    => '',
135             'value'        => '',
136             'width'        => '30',
137             'maxlength'    => '255'
138         ),
139         'webftp_url' => array (
140             'datatype'    => 'VARCHAR',
141             'formtype'    => 'TEXT',
142             'validators'    => array (     0 => array (    'type'    => 'REGEX',
143                                                         'regex' => '/^[0-9a-zA-Z\:\/\-\.]{0,255}$/',
144                                                         'errmsg'=> 'webftp_url_error_regex'),
145                                         ),
146             'default'    => '',
147             'value'        => '',
148             'width'        => '30',
149             'maxlength'    => '255'
150         ),
151     ##################################
152     # ENDE Datatable fields
153     ##################################
154     )
155 );
156
157 $form["tabs"]['mail'] = array (
158     'title'     => "Mail",
159     'width'     => 70,
160     'template'     => "templates/system_config_mail_edit.htm",
161     'fields'     => array (
162     ##################################
163     # Begin Datatable fields
164     ##################################
165     'enable_custom_login' => array(
166       'datatype' => 'VARCHAR',
167       'formtype' => 'CHECKBOX',
168       'default' => 'n',
169       'value' => array(0 => 'n', 1 => 'y')
170     ),
171         'mailboxlist_webmail_link' => array (
172             'datatype'    => 'VARCHAR',
173             'formtype'    => 'CHECKBOX',
174             'default'    => 'n',
175             'value'        => array(0 => 'n',1 => 'y')
176         ),
177         'webmail_url' => array (
178             'datatype'    => 'VARCHAR',
179             'formtype'    => 'TEXT',
180             'validators'    => array (     0 => array (    'type'    => 'REGEX',
181                                                         'regex' => '/^[0-9a-zA-Z\:\/\-\.]{0,255}$/',
182                                                         'errmsg'=> 'webmail_url_error_regex'),
183                                         ),
184             'default'    => '',
185             'value'        => '',
186             'width'        => '30',
187             'maxlength'    => '255'
188         ),
189         'mailmailinglist_link' => array (
190             'datatype'    => 'VARCHAR',
191             'formtype'    => 'CHECKBOX',
192             'default'    => 'n',
193             'value'        => array(0 => 'n',1 => 'y')
194         ),
195         'mailmailinglist_url' => array (
196             'datatype'    => 'VARCHAR',
197             'formtype'    => 'TEXT',
198             'validators'    => array (     0 => array (    'type'    => 'REGEX',
199                                                         'regex' => '/^[0-9a-zA-Z\:\/\-\.]{0,255}$/',
200                                                         'errmsg'=> 'mailinglist_url_error_regex'),
201                                         ),
202             'default'    => '',
203             'value'        => '',
204             'width'        => '30',
205             'maxlength'    => '255'
206         ),
207         'admin_mail' => array (
208             'datatype'    => 'VARCHAR',
209             'formtype'    => 'TEXT',
210             'default'    => '',
211             'value'        => '',
212             'width'        => '30',
213             'maxlength'    => '255'
214         ),
215         'admin_name' => array (
216             'datatype'    => 'VARCHAR',
217             'formtype'    => 'TEXT',
218             'default'    => '',
219             'value'        => '',
220             'width'        => '30',
221             'maxlength'    => '255'
222         ),
223     ##################################
224     # ENDE Datatable fields
225     ##################################
226     )
227 );
228
229 $form["tabs"]['domains'] = array (
230     'title'     => "Domains",
231     'width'     => 70,
232     'template'     => "templates/system_config_domains_edit.htm",
233     'fields'     => array (
234     ##################################
235     # Begin Datatable fields
236     ##################################
237         'use_domain_module' => array (
238             'datatype'    => 'VARCHAR',
239             'formtype'    => 'CHECKBOX',
240             'default'    => 'n',
241             'value'        => array(0 => 'n',1 => 'y')
242         ),
243         'new_domain_html' => array (
244             'datatype'    => 'VARCHAR',
245             'formtype'    => 'TEXT',
246             'default'    => '',
247             'value'        => ''
248         ),
249     ##################################
250     # ENDE Datatable fields
251     ##################################
252     )
253 );
254
255 $form["tabs"]['misc'] = array (
256     'title'     => "Misc",
257     'width'     => 70,
258     'template'     => "templates/system_config_misc_edit.htm",
259     'fields'     => array (
260     ##################################
261     # Begin Datatable fields
262     ##################################
263         'dashboard_atom_url_admin' => array (
264             'datatype'    => 'VARCHAR',
265             'formtype'    => 'TEXT',
266             'default'    => 'http://www.ispconfig.org/atom',
267             'value'        => ''
268         ),
269         'dashboard_atom_url_reseller' => array (
270             'datatype'    => 'VARCHAR',
271             'formtype'    => 'TEXT',
272             'default'    => 'http://www.ispconfig.org/atom',
273             'value'        => ''
274         ),
275         'dashboard_atom_url_client' => array (
276             'datatype'    => 'VARCHAR',
277             'formtype'    => 'TEXT',
278             'default'    => 'http://www.ispconfig.org/atom',
279             'value'        => ''
280         ),
281         'monitor_key' => array (
282             'datatype'    => 'VARCHAR',
283             'formtype'    => 'TEXT',
284             'default'    => '',
285             'value'        => ''
286         ),
287     ##################################
288     # ENDE Datatable fields
289     ##################################
290     )
291 );
292
293
294 ?>