client.tform.php 31.3 KB
Newer Older
latham's avatar
latham committed
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
<?php

/*
	Form Definition

	Tabledefinition

	Datatypes:
	- INTEGER (Forces the input to Int)
	- DOUBLE
	- CURRENCY (Formats the values to currency notation)
	- VARCHAR (no format check, maxlength: 255)
	- TEXT (no format check)
	- DATE (Dateformat, automatic conversion to timestamps)

	Formtype:
	- TEXT (Textfield)
	- TEXTAREA (Textarea)
	- PASSWORD (Password textfield, input is not shown when edited)
	- SELECT (Select option field)
	- RADIO
	- CHECKBOX
	- CHECKBOXARRAY
	- FILE

	VALUE:
	- Wert oder Array

	Hint:
	The ID field of the database table is not part of the datafield definition.
	The ID field must be always auto incement (int or bigint).
32

33
34
35
36
	Search:
	- searchable = 1 or searchable = 2 include the field in the search
	- searchable = 1: this field will be the title of the search result
	- searchable = 2: this field will be included in the description of the search result
latham's avatar
latham committed
37
38
39
40


*/

41
$form["title"]   = "Client";
42
$form["description"]    = "";
43
44
45
46
47
48
49
50
$form["name"]   = "client";
$form["action"]  = "client_edit.php";
$form["db_table"] = "client";
$form["db_table_idx"] = "client_id";
$form["db_history"] = "yes";
$form["tab_default"] = "address";
$form["list_default"] = "client_list.php";
$form["auth"]  = 'yes';
latham's avatar
latham committed
51
52
53
54
55
56
57
58
59
60

$form["auth_preset"]["userid"]  = 0; // 0 = id of the user, > 0 id must match with id of current user
$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete

//* Languages
$language_list = array();
$handle = @opendir(ISPC_ROOT_PATH.'/lib/lang');
61
62
63
while ($file = @readdir($handle)) {
	if ($file != '.' && $file != '..') {
		if(@is_file(ISPC_ROOT_PATH.'/lib/lang/'.$file) and substr($file, -4, 4) == '.lng') {
latham's avatar
latham committed
64
65
			$tmp = substr($file, 0, 2);
			$language_list[$tmp] = $tmp;
66
		}
latham's avatar
latham committed
67
68
69
70
71
	}
}

//* Load themes
$themes_list = array();
72
73
74
75
$handle = @opendir(ISPC_THEMES_PATH);
while ($file = @readdir($handle)) {
	if (substr($file, 0, 1) != '.') {
		if(@is_dir(ISPC_THEMES_PATH."/$file")) {
76
			if(!file_exists(ISPC_THEMES_PATH."/$file/ispconfig_version") || (@file_exists(ISPC_THEMES_PATH."/$file/ispconfig_version") && trim(@file_get_contents(ISPC_THEMES_PATH."/$file/ispconfig_version")) == ISPC_APP_VERSION)) {
77
78
79
				$themes_list[$file] = $file;
			}
		}
latham's avatar
latham committed
80
81
82
83
	}
}

$form["tabs"]['address'] = array (
84
85
86
87
88
89
90
	'title'  => "Address",
	'width'  => 100,
	'template'  => "templates/client_edit_address.htm",
	'fields'  => array (
		//#################################
		// Begin Datatable fields
		//#################################
latham's avatar
latham committed
91
		'company_name' => array (
92
93
94
95
96
97
98
99
100
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
101
			'searchable' => 2
latham's avatar
latham committed
102
		),
103
		'gender' => array (
104
105
106
107
			'datatype' => 'VARCHAR',
			'formtype' => 'SELECT',
			'default' => '',
			'value'  => array('' => '', 'm' => 'gender_m_txt', 'f' => 'gender_f_txt')
108
		),
109
110
111
112
113
114
115
116
117
118
119
120
		'contact_firstname' => array (
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
			'searchable' => 1
		),
latham's avatar
latham committed
121
		'contact_name' => array (
122
123
124
125
126
127
128
129
130
131
132
133
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
					'errmsg'=> 'contact_error_empty'),
			),
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
134
			'searchable' => 1
latham's avatar
latham committed
135
136
		),
		'customer_no' => array (
137
138
139
140
141
142
143
144
145
146
147
148
149
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'UNIQUE',
					'errmsg'=> 'customer_no_error_unique',
					'allowempty' => 'y'),
			),
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
150
			'searchable' => 2
latham's avatar
latham committed
151
152
		),
		'username' => array (
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'NOTEMPTY',
					'errmsg'=> 'username_error_empty'),
				1 => array ( 'type' => 'CUSTOM',
					'class' => 'validate_client',
					'function' => 'username_unique',
					'errmsg'=> 'username_error_unique'),
				2 => array ( 'type' => 'CUSTOM',
					'class' => 'validate_client',
					'function' => 'username_collision',
					'errmsg'=> 'username_error_collision'),
				3 => array ( 'type' => 'REGEX',
					'regex' => '/^[\w\.\-\_]{0,64}$/',
					'errmsg'=> 'username_error_regex'),
			),
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
176
			'searchable' => 2
latham's avatar
latham committed
177
178
		),
		'password' => array (
179
180
			'datatype' => 'VARCHAR',
			'formtype' => 'PASSWORD',
181
182
183
184
185
186
187
188
			'validators' => array(
				0 => array(
					'type' => 'CUSTOM',
					'class' => 'validate_password',
					'function' => 'password_check',
					'errmsg' => 'weak_password_txt'
				)
			),
latham's avatar
latham committed
189
			'encryption'=> 'CRYPT',
190
191
192
193
194
195
196
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
197
198
		),
		'language' => array (
199
200
201
202
203
204
205
206
207
			'datatype' => 'VARCHAR',
			'formtype' => 'SELECT',
			'default' => $conf["language"],
			'value'  => $language_list,
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
208
209
		),
		'usertheme' => array (
210
211
212
213
214
215
216
217
218
			'datatype' => 'VARCHAR',
			'formtype' => 'SELECT',
			'default' => $conf["theme"],
			'value'  => $themes_list,
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
219
220
		),
		'street' => array (
221
222
223
224
225
226
227
228
229
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
230
			'searchable' => 2
latham's avatar
latham committed
231
232
		),
		'zip' => array (
233
234
235
236
237
238
239
240
241
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
242
			'searchable' => 2
latham's avatar
latham committed
243
244
		),
		'city' => array (
245
246
247
248
249
250
251
252
253
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
254
			'searchable' => 2
latham's avatar
latham committed
255
256
		),
		'state' => array (
257
258
259
260
261
262
263
264
265
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
266
			'searchable' => 2
latham's avatar
latham committed
267
268
		),
		'country' => array (
269
270
271
272
			'datatype' => 'VARCHAR',
			'formtype' => 'SELECT',
			'default' => (isset($conf['language']) ? strtoupper($conf['language']) : ''),
			'datasource' => array (  'type'          => 'SQL',
273
				'querystring'   => 'SELECT iso,printable_name FROM country ORDER BY printable_name ASC',
274
275
276
277
				'keyfield'      => 'iso',
				'valuefield'    => 'printable_name'
			),
			'value'  => ''
latham's avatar
latham committed
278
279
		),
		'telephone' => array (
280
281
282
283
284
285
286
287
288
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
289
			'searchable' => 2
latham's avatar
latham committed
290
291
		),
		'mobile' => array (
292
293
294
295
296
297
298
299
300
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
301
			'searchable' => 2
latham's avatar
latham committed
302
303
		),
		'fax' => array (
304
305
306
307
308
309
310
311
312
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
313
			'searchable' => 2
latham's avatar
latham committed
314
315
		),
		'email' => array (
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'filters'   => array( 0 => array( 'event' => 'SAVE',
					'type' => 'IDNTOASCII'),
				1 => array( 'event' => 'SHOW',
					'type' => 'IDNTOUTF8'),
				2 => array( 'event' => 'SAVE',
					'type' => 'TOLOWER')
			),
			'validators' => array (  0 => array ( 'type' => 'REGEX',
					'regex' => '/^(\w+[\w\.\-\+]*\w{0,}@\w+[\w.-]*\.[a-z\-]{2,10}){0,1}$/i',
					'errmsg'=> 'email_error_isemail'),
			),
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
336
			'searchable' => 2
latham's avatar
latham committed
337
338
		),
		'internet' => array (
339
340
341
342
343
344
345
346
347
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => 'http://',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
348
			'searchable' => 2
latham's avatar
latham committed
349
350
		),
		'icq' => array (
351
352
353
354
355
356
357
358
359
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
360
361
		),
		'vat_id' => array (
362
363
364
365
366
367
368
369
370
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
371
372
		),
		'company_id' => array (
373
374
375
376
377
378
379
380
381
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
382
		),
383
		'bank_account_owner' => array (
384
385
386
387
388
389
390
391
392
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
393
		),
394
		'bank_account_number' => array (
395
396
397
398
399
400
401
402
403
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
404
405
		),
		'bank_code' => array (
406
407
408
409
410
411
412
413
414
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
415
416
		),
		'bank_name' => array (
417
418
419
420
421
422
423
424
425
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
426
427
		),
		'bank_account_iban' => array (
428
429
430
431
432
433
434
435
436
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
437
438
		),
		'bank_account_swift' => array (
439
440
441
442
443
444
445
446
447
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
448
		),
latham's avatar
latham committed
449
		'notes' => array (
450
451
452
453
454
455
456
457
458
			'datatype' => 'TEXT',
			'formtype' => 'TEXTAREA',
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '',
			'maxlength' => '',
			'rows'  => '10',
			'cols'  => '30'
latham's avatar
latham committed
459
		),
460
		'paypal_email' => array (
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'filters'   => array( 0 => array( 'event' => 'SAVE',
					'type' => 'IDNTOASCII'),
				1 => array( 'event' => 'SHOW',
					'type' => 'IDNTOUTF8'),
				2 => array( 'event' => 'SAVE',
					'type' => 'TOLOWER')
			),
			'validators' => array (  0 => array ( 'type' => 'REGEX',
					'regex' => '/^(\w+[\w\.\-\+]*\w{0,}@\w+[\w.-]*\.[a-z\-]{2,10}){0,1}$/i',
					'errmsg'=> 'paypal_email_error_isemail'),
			),
			'default' => '',
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => '',
481
482
			'searchable' => 2
		),
483
		'locked' => array (
484
485
486
487
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOX',
			'default' => 'n',
			'value'  => array(0 => 'n', 1 => 'y')
488
489
		),
		'canceled' => array (
490
491
492
493
494
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOX',
			'default' => 'n',
			'value'  => array(0 => 'n', 1 => 'y')
		),
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
		'added_date' => array (
			'datatype'	=> 'DATE',
			'formtype'	=> 'TEXT',
			'default'	=> date($app->lng('conf_format_dateshort')),
			'value'		=> '',
			'separator'	=> '',
			'width'		=> '15',
			'maxlength'	=> '15',
			'rows'		=> '',
			'cols'		=> ''
		),
		'added_by' => array (
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
			'default' => $_SESSION['s']['user']['username'],
			'value'  => '',
			'separator' => '',
			'width'  => '30',
			'maxlength' => '255',
			'rows'  => '',
			'cols'  => ''
		),
517
518
519
		//#################################
		// END Datatable fields
		//#################################
latham's avatar
latham committed
520
521
522
523
	)
);

$form["tabs"]['limits'] = array (
524
525
526
527
528
529
530
	'title'  => "Limits",
	'width'  => 80,
	'template'  => "templates/client_edit_limits.htm",
	'fields'  => array (
		//#################################
		// Begin Datatable fields
		//#################################
latham's avatar
latham committed
531
		'template_master' => array (
532
533
534
535
536
537
538
539
			'datatype' => 'INTEGER',
			'formtype' => 'SELECT',
			'default' => '1',
			'datasource' => array (  'type' => 'CUSTOM',
				'class'=> 'custom_datasource',
				'function'=> 'master_templates'
			),
			'value'  => ''
latham's avatar
latham committed
540
541
		),
		'template_additional' => array (
542
543
			'datatype' => 'VARCHAR',
			'formtype' => 'TEXT',
latham's avatar
latham committed
544
545
		),
		'default_mailserver' => array (
546
547
548
549
550
551
552
553
554
			'datatype' => 'INTEGER',
			'formtype' => 'SELECT',
			'default' => '1',
			'datasource' => array (  'type' => 'CUSTOM',
				'class'=> 'custom_datasource',
				'function'=> 'client_servers'
			),
			'value'  => '',
			'name'  => 'default_mailserver'
latham's avatar
latham committed
555
		),
556
		'mail_servers' => array (
557
558
			'datatype' => 'VARCHAR',
			'formtype' => 'MULTIPLE',
559
			'separator' => ',',
560
561
562
563
564
			'default' => '1',
			'datasource' => array (  'type' => 'CUSTOM',
				'class'=> 'custom_datasource',
				'function'=> 'client_servers'
			),
565
			'validators'    => array (  0 => array (    'type'  => 'NOTEMPTY',
566
567
568
569
570
571
572
573
					'errmsg'=> 'no_mail_server_error'),
				1 => array ( 'type' => 'CUSTOM',
					'class' => 'validate_client',
					'function' => 'check_used_servers',
					'errmsg'=> 'mail_servers_used'),
			),
			'value'  => '',
			'name'  => 'mail_servers'
574
		),
latham's avatar
latham committed
575
		'limit_maildomain' => array (
576
577
578
579
580
581
582
583
584
585
586
587
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_maildomain_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
588
589
		),
		'limit_mailbox' => array (
590
591
592
593
594
595
596
597
598
599
600
601
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_mailbox_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
602
603
		),
		'limit_mailalias' => array (
604
605
606
607
608
609
610
611
612
613
614
615
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_mailalias_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
616
617
		),
		'limit_mailaliasdomain' => array (
618
619
620
621
622
623
624
625
626
627
628
629
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_mailaliasdomain_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
630
631
		),
		'limit_mailmailinglist' => array (
632
633
634
635
636
637
638
639
640
641
642
643
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_mailmailinglist_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
644
645
		),
		'limit_mailforward' => array (
646
647
648
649
650
651
652
653
654
655
656
657
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_mailforward_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
658
659
		),
		'limit_mailcatchall' => array (
660
661
662
663
664
665
666
667
668
669
670
671
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_mailcatchall_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
672
673
		),
		'limit_mailrouting' => array (
674
675
676
677
678
679
680
681
682
683
684
685
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_mailrouting_error_notint'),
			),
			'default' => '0',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
686
687
		),
		'limit_mailfilter' => array (
688
689
690
691
692
693
694
695
696
697
698
699
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_mailfilter_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
700
701
		),
		'limit_fetchmail' => array (
702
703
704
705
706
707
708
709
710
711
712
713
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_mailfetchmail_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
714
715
		),
		'limit_mailquota' => array (
716
717
718
719
720
721
722
723
724
725
726
727
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_mailquota_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
728
729
		),
		'limit_spamfilter_wblist' => array (
730
731
732
733
734
735
736
737
738
739
740
741
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_spamfilter_wblist_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
742
743
		),
		'limit_spamfilter_user' => array (
744
745
746
747
748
749
750
751
752
753
754
755
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_spamfilter_user_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
756
757
		),
		'limit_spamfilter_policy' => array (
758
759
760
761
762
763
764
765
766
767
768
769
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_spamfilter_policy_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
770
771
		),
		'default_webserver' => array (
772
773
774
775
776
777
778
779
780
			'datatype' => 'INTEGER',
			'formtype' => 'SELECT',
			'default' => '1',
			'datasource' => array (  'type' => 'CUSTOM',
				'class'=> 'custom_datasource',
				'function'=> 'client_servers'
			),
			'value'  => '',
			'name'  => 'default_webserver'
latham's avatar
latham committed
781
		),
782
		'web_servers' => array (
783
784
			'datatype' => 'VARCHAR',
			'formtype' => 'MULTIPLE',
785
			'separator' => ',',
786
787
788
789
790
			'default' => '1',
			'datasource' => array (  'type' => 'CUSTOM',
				'class'=> 'custom_datasource',
				'function'=> 'client_servers'
			),
791
			'validators'    => array (  0 => array (    'type'  => 'NOTEMPTY',
792
793
794
795
796
797
798
799
					'errmsg'=> 'no_web_server_error'),
				1 => array ( 'type' => 'CUSTOM',
					'class' => 'validate_client',
					'function' => 'check_used_servers',
					'errmsg'=> 'web_servers_used'),
			),
			'value'  => '',
			'name'  => 'web_servers'
800
		),
latham's avatar
latham committed
801
		'limit_web_domain' => array (
802
803
804
805
806
807
808
809
810
811
812
813
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_web_domain_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
814
815
		),
		'limit_web_quota' => array (
816
817
818
819
820
821
822
823
824
825
826
827
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_web_quota_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
828
829
		),
		'web_php_options' => array (
830
831
832
833
834
835
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOXARRAY',
			'validators' => array (  0 => array ( 'type' => 'NOTEMPTY',
					'errmsg'=> 'web_php_options_notempty'),
			),
			'default' => '',
latham's avatar
latham committed
836
837
			'separator' => ',',
			'valuelimit' => 'client:web_php_options',
838
			'value'  => array('no' => 'Disabled', 'fast-cgi' => 'Fast-CGI', 'cgi' => 'CGI', 'mod' => 'Mod-PHP', 'suphp' => 'SuPHP', 'php-fpm' => 'PHP-FPM', 'hhvm' => 'HHVM')
latham's avatar
latham committed
839
		),
mcramer's avatar
mcramer committed
840
		'limit_cgi' => array (
841
842
843
844
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOX',
			'default' => 'n',
			'value'  => array(0 => 'n', 1 => 'y')
mcramer's avatar
mcramer committed
845
846
		),
		'limit_ssi' => array (
847
848
849
850
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOX',
			'default' => 'n',
			'value'  => array(0 => 'n', 1 => 'y')
mcramer's avatar
mcramer committed
851
852
		),
		'limit_perl' => array (
853
854
855
856
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOX',
			'default' => 'n',
			'value'  => array(0 => 'n', 1 => 'y')
mcramer's avatar
mcramer committed
857
858
		),
		'limit_ruby' => array (
859
860
861
862
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOX',
			'default' => 'n',
			'value'  => array(0 => 'n', 1 => 'y')
mcramer's avatar
mcramer committed
863
864
		),
		'limit_python' => array (
865
866
867
868
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOX',
			'default' => 'n',
			'value'  => array(0 => 'n', 1 => 'y')
mcramer's avatar
mcramer committed
869
870
		),
		'force_suexec' => array (
871
872
873
874
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOX',
			'default' => 'y',
			'value'  => array(0 => 'n', 1 => 'y')
mcramer's avatar
mcramer committed
875
876
		),
		'limit_hterror' => array (
877
878
879
880
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOX',
			'default' => 'n',
			'value'  => array(0 => 'n', 1 => 'y')
mcramer's avatar
mcramer committed
881
882
		),
		'limit_wildcard' => array (
883
884
885
886
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOX',
			'default' => 'n',
			'value'  => array(0 => 'n', 1 => 'y')
mcramer's avatar
mcramer committed
887
888
		),
		'limit_ssl' => array (
889
890
891
892
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOX',
			'default' => 'n',
			'value'  => array(0 => 'n', 1 => 'y')
mcramer's avatar
mcramer committed
893
		),
latham's avatar
latham committed
894
		'limit_web_aliasdomain' => array (
895
896
897
898
899
900
901
902
903
904
905
906
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_web_aliasdomain_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
907
908
		),
		'limit_web_subdomain' => array (
909
910
911
912
913
914
915
916
917
918
919
920
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_web_subdomain_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
921
922
		),
		'limit_ftp_user' => array (
923
924
925
926
927
928
929
930
931
932
933
934
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_ftp_user_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
935
936
		),
		'limit_shell_user' => array (
937
938
939
940
941
942
943
944
945
946
947
948
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_shell_user_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
949
950
		),
		'ssh_chroot' => array (
951
952
953
954
955
956
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOXARRAY',
			'validators' => array (  0 => array ( 'type' => 'NOTEMPTY',
					'errmsg'=> 'ssh_chroot_notempty'),
			),
			'default' => '',
latham's avatar
latham committed
957
958
			'separator' => ',',
			'valuelimit' => 'client:ssh_chroot',
959
			'value'  => array('no' => 'None', 'jailkit' => 'Jailkit')
latham's avatar
latham committed
960
961
		),
		'limit_webdav_user' => array (
962
963
964
965
966
967
968
969
970
971
972
973
			'datatype' => 'INTEGER',
			'formtype' => 'TEXT',
			'validators' => array (  0 => array ( 'type' => 'ISINT',
					'errmsg'=> 'limit_webdav_user_error_notint'),
			),
			'default' => '-1',
			'value'  => '',
			'separator' => '',
			'width'  => '10',
			'maxlength' => '10',
			'rows'  => '',
			'cols'  => ''
latham's avatar
latham committed
974
		),
975
976
977
		'limit_backup' => array (
			'datatype' => 'VARCHAR',
			'formtype' => 'CHECKBOX',
Dominik's avatar
Dominik committed
978
			'default' => 'y',
979
980
			'value'  => array(0 => 'n', 1 => 'y')
		),
latham's avatar
latham committed
981
		'default_dnsserver' => array (
982
983
984
985
986
987
988
989
990
			'datatype' => 'INTEGER',
			'formtype' => 'SELECT',
			'default' => '1',
			'datasource' => array (  'type' => 'CUSTOM',
				'class'=> 'custom_datasource',
				'function'=> 'client_servers'
			),
			'value'  => '',
			'name'  => 'default_dnsserver'
latham's avatar
latham committed
991
		),
992
		'dns_servers' => array (
993
994
			'datatype' => 'VARCHAR',
			'formtype' => 'MULTIPLE',
995
			'separator' => ',',
996
997
998
999
1000
			'default' => '1',
			'datasource' => array (  'type' => 'CUSTOM',
				'class'=> 'custom_datasource',
				'function'=> 'client_servers'
			),
For faster browsing, not all history is shown. View entire blame