| | |
| | |
|
| | | */
|
| | |
|
| | | $form["title"] = "Reseller";
|
| | | $form["title"] = "Client";
|
| | | $form["description"] = "";
|
| | | $form["name"] = "reseller";
|
| | | $form["action"] = "reseller_edit.php";
|
| | | $form["db_table"] = "reseller";
|
| | | $form["db_table_idx"] = "reseller_id";
|
| | | $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"] = "reseller_list.php";
|
| | | $form["list_default"] = "client_list.php";
|
| | | $form["auth"] = 'yes';
|
| | |
|
| | | $form["auth_preset"]["userid"] = 0; // 0 = id of the user, > 0 id must match with id of current user
|
| | |
| | | $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');
|
| | | while ($file = @readdir ($handle)) {
|
| | | if ($file != '.' && $file != '..') {
|
| | | if(@is_file(ISPC_ROOT_PATH.'/lib/lang/'.$file) and substr($file,-4,4) == '.lng') {
|
| | | $tmp = substr($file, 0, 2);
|
| | | $language_list[$tmp] = $tmp;
|
| | | }
|
| | | }
|
| | | }
|
| | |
|
| | | $form["tabs"]['address'] = array (
|
| | | 'title' => "Address",
|
| | | 'width' => 100,
|
| | | 'template' => "templates/reseller_edit_address.htm",
|
| | | 'template' => "templates/client_edit_address.htm",
|
| | | 'fields' => array (
|
| | | ##################################
|
| | | # Begin Datatable fields
|
| | | ##################################
|
| | | 'company' => array (
|
| | | 'company_name' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | | 'formtype' => 'TEXT',
|
| | | 'default' => '',
|
| | |
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'title' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | | 'formtype' => 'SELECT',
|
| | | 'default' => '',
|
| | | 'value' => array('Mrs.' => 'Mrs.','Mr.'=>'Mr.','Company'=>'Company'),
|
| | | 'separator' => '',
|
| | | 'width' => '',
|
| | | 'maxlength' => '255',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'firstname' => array (
|
| | | 'contact_name' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | | 'formtype' => 'TEXT',
|
| | | 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
|
| | | 'errmsg'=> 'firstname_error_empty'),
|
| | | ),
|
| | | 'default' => '',
|
| | | 'value' => '',
|
| | | 'separator' => '',
|
| | | 'width' => '30',
|
| | | 'maxlength' => '255',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'surname' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | | 'formtype' => 'TEXT',
|
| | | 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
|
| | | 'errmsg'=> 'surname_error_empty'),
|
| | | 'errmsg'=> 'contact_error_empty'),
|
| | | ),
|
| | | 'default' => '',
|
| | | 'value' => '',
|
| | | 'separator' => '',
|
| | | 'width' => '30',
|
| | | 'maxlength' => '255',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'username' => array (
|
| | | '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' => 'REGEX',
|
| | | 'regex' => '/^[\w\.\-\_]{0,64}$/',
|
| | | 'errmsg'=> 'username_error_regex'),
|
| | | ),
|
| | | 'default' => '',
|
| | | 'value' => '',
|
| | | 'separator' => '',
|
| | | 'width' => '30',
|
| | | 'maxlength' => '255',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'password' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | | 'formtype' => 'PASSWORD',
|
| | | 'encryption'=> 'CRYPT',
|
| | | 'default' => '',
|
| | | 'value' => '',
|
| | | 'separator' => '',
|
| | | 'width' => '30',
|
| | | 'maxlength' => '255',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'language' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | | 'formtype' => 'SELECT',
|
| | | 'default' => $conf["language"],
|
| | | 'value' => $language_list,
|
| | | 'separator' => '',
|
| | | 'width' => '30',
|
| | | 'maxlength' => '255',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'usertheme' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | | 'formtype' => 'SELECT',
|
| | | 'default' => 'default',
|
| | | 'value' => array('default' => 'default'),
|
| | | 'separator' => '',
|
| | | 'width' => '30',
|
| | | 'maxlength' => '255',
|
| | |
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'country' => array (
|
| | | 'state' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | | 'formtype' => 'TEXT',
|
| | | 'default' => '',
|
| | |
| | | 'maxlength' => '255',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'country' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | |
|
| | | 'formtype' => 'SELECT',
|
| | | 'default' => 'DE',
|
| | | 'datasource' => array ( 'type' => 'SQL',
|
| | | 'querystring' => 'SELECT iso,printable_name FROM country ORDER BY printable_name',
|
| | | 'keyfield'=> 'iso',
|
| | | 'valuefield'=> 'printable_name'
|
| | | ),
|
| | | 'value' => ''
|
| | | ),
|
| | | 'telephone' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | |
| | | 'cols' => '30'
|
| | | ),
|
| | | ##################################
|
| | | # ENDE Datatable fields
|
| | | # END Datatable fields
|
| | | ##################################
|
| | | )
|
| | | );
|
| | |
| | | $form["tabs"]['limits'] = array (
|
| | | 'title' => "Limits",
|
| | | 'width' => 80,
|
| | | 'template' => "templates/reseller_edit_limits.htm",
|
| | | 'template' => "templates/client_edit_limits.htm",
|
| | | 'fields' => array (
|
| | | ##################################
|
| | | # Beginn Datatable fields
|
| | | # Begin Datatable fields
|
| | | ##################################
|
| | | 'limit_client' => array (
|
| | | 'template_master' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'formtype' => 'TEXT',
|
| | | 'validators' => array ( 0 => array ( 'type' => 'ISINT',
|
| | | 'errmsg'=> 'limit_client_error_notint'),
|
| | | ),
|
| | | 'default' => '-1',
|
| | | 'value' => '',
|
| | | 'separator' => '',
|
| | | 'width' => '10',
|
| | | 'maxlength' => '10',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | 'formtype' => 'SELECT',
|
| | | 'default' => '1',
|
| | | 'datasource' => array ( 'type' => 'CUSTOM',
|
| | | 'class'=> 'custom_datasource',
|
| | | 'function'=> 'master_templates'
|
| | | ),
|
| | | 'value' => ''
|
| | | ),
|
| | | 'limit_domain' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'template_additional' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | | 'formtype' => 'TEXT',
|
| | | 'validators' => array ( 0 => array ( 'type' => 'ISINT',
|
| | | 'errmsg'=> 'limit_domain_error_notint'),
|
| | | ),
|
| | | 'default' => '-1',
|
| | | 'value' => '',
|
| | | 'separator' => '',
|
| | | 'width' => '10',
|
| | | 'maxlength' => '10',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'limit_subdomain' => array (
|
| | | 'default_mailserver' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'formtype' => 'SELECT',
|
| | | 'default' => '1',
|
| | | 'datasource' => array ( 'type' => 'SQL',
|
| | | 'querystring' => 'SELECT server_id,server_name FROM server WHERE mail_server = 1 AND {AUTHSQL} ORDER BY server_name',
|
| | | 'keyfield'=> 'server_id',
|
| | | 'valuefield'=> 'server_name'
|
| | | ),
|
| | | 'value' => ''
|
| | | ),
|
| | | 'limit_maildomain' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'formtype' => 'TEXT',
|
| | | 'validators' => array ( 0 => array ( 'type' => 'ISINT',
|
| | | 'errmsg'=> 'limit_client_subdomain_notint'),
|
| | | 'errmsg'=> 'limit_maildomain_error_notint'),
|
| | | ),
|
| | | 'default' => '-1',
|
| | | 'value' => '',
|
| | |
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'limit_webquota' => array (
|
| | | 'limit_mailforward' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'formtype' => 'TEXT',
|
| | | 'validators' => array ( 0 => array ( 'type' => 'ISINT',
|
| | | 'errmsg'=> 'limit_webquota_error_notint'),
|
| | | 'errmsg'=> 'limit_mailforward_error_notint'),
|
| | | ),
|
| | | 'default' => '-1',
|
| | | 'value' => '',
|
| | | 'separator' => '',
|
| | | 'width' => '10',
|
| | | 'maxlength' => '10',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'limit_mailcatchall' => array (
|
| | | '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' => ''
|
| | | ),
|
| | | 'limit_mailrouting' => array (
|
| | | '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' => ''
|
| | | ),
|
| | | 'limit_mailfilter' => array (
|
| | | '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' => ''
|
| | | ),
|
| | | 'limit_fetchmail' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'formtype' => 'TEXT',
|
| | | 'validators' => array ( 0 => array ( 'type' => 'ISINT',
|
| | | 'errmsg'=> 'limit_mailfetchmail_error_notint'),
|
| | | ),
|
| | | 'default' => '-1',
|
| | | 'value' => '',
|
| | |
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'limit_spamfilter_wblist' => array (
|
| | | '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' => ''
|
| | | ),
|
| | | 'limit_spamfilter_user' => array (
|
| | | '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' => ''
|
| | | ),
|
| | | 'limit_spamfilter_policy' => array (
|
| | | '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' => ''
|
| | | ),
|
| | | 'default_webserver' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'formtype' => 'SELECT',
|
| | | 'default' => '1',
|
| | | 'datasource' => array ( 'type' => 'SQL',
|
| | | 'querystring' => 'SELECT server_id,server_name FROM server WHERE web_server = 1 AND {AUTHSQL} ORDER BY server_name',
|
| | | 'keyfield'=> 'server_id',
|
| | | 'valuefield'=> 'server_name'
|
| | | ),
|
| | | 'value' => ''
|
| | | ),
|
| | | 'limit_web_domain' => array (
|
| | | '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' => ''
|
| | | ),
|
| | | 'web_php_options' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | | 'formtype' => 'CHECKBOXARRAY',
|
| | | 'default' => '',
|
| | | 'separator' => ',',
|
| | | 'value' => array('no' => 'Disabled', 'fast-cgi' => 'Fast-CGI', 'cgi' => 'CGI', 'mod' => 'Mod-PHP', 'suphp' => 'SuPHP')
|
| | | ),
|
| | | 'limit_web_aliasdomain' => array (
|
| | | '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' => ''
|
| | | ),
|
| | | 'limit_web_subdomain' => array (
|
| | | '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' => ''
|
| | | ),
|
| | | 'limit_ftp_user' => array (
|
| | | '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' => ''
|
| | | ),
|
| | | 'limit_shell_user' => array (
|
| | | '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' => ''
|
| | | ),
|
| | | 'ssh_chroot' => array (
|
| | | 'datatype' => 'VARCHAR',
|
| | | 'formtype' => 'CHECKBOXARRAY',
|
| | | 'default' => '',
|
| | | 'separator' => ',',
|
| | | 'value' => array('no' => 'None', 'jailkit' => 'Jailkit')
|
| | | ),
|
| | | 'default_dnsserver' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'formtype' => 'SELECT',
|
| | | 'default' => '1',
|
| | | 'datasource' => array ( 'type' => 'SQL',
|
| | | 'querystring' => 'SELECT server_id,server_name FROM server WHERE dns_server = 1 AND {AUTHSQL} ORDER BY server_name',
|
| | | 'keyfield'=> 'server_id',
|
| | | 'valuefield'=> 'server_name'
|
| | | ),
|
| | | 'value' => ''
|
| | | ),
|
| | | 'limit_dns_zone' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'formtype' => 'TEXT',
|
| | | 'validators' => array ( 0 => array ( 'type' => 'ISINT',
|
| | | 'errmsg'=> 'limit_dns_zone_error_notint'),
|
| | | ),
|
| | | 'default' => '-1',
|
| | | 'value' => '',
|
| | | 'separator' => '',
|
| | | 'width' => '10',
|
| | | 'maxlength' => '10',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'limit_dns_record' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'formtype' => 'TEXT',
|
| | | 'validators' => array ( 0 => array ( 'type' => 'ISINT',
|
| | | 'errmsg'=> 'limit_dns_record_error_notint'),
|
| | | ),
|
| | | 'default' => '-1',
|
| | | 'value' => '',
|
| | | 'separator' => '',
|
| | | 'width' => '10',
|
| | | 'maxlength' => '10',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'limit_client' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'formtype' => 'TEXT',
|
| | | 'validators' => array ( 0 => array ( 'type' => 'ISINT',
|
| | | 'errmsg'=> 'limit_client_error_notint'),
|
| | | ),
|
| | | 'default' => '0',
|
| | | 'value' => '',
|
| | | 'separator' => '',
|
| | | 'width' => '10',
|
| | | 'maxlength' => '10',
|
| | | 'rows' => '',
|
| | | 'cols' => ''
|
| | | ),
|
| | | 'default_dbserver' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'formtype' => 'SELECT',
|
| | | 'default' => '1',
|
| | | 'datasource' => array ( 'type' => 'SQL',
|
| | | 'querystring' => 'SELECT server_id,server_name FROM server WHERE db_server = 1 AND {AUTHSQL} ORDER BY server_name',
|
| | | 'keyfield'=> 'server_id',
|
| | | 'valuefield'=> 'server_name'
|
| | | ),
|
| | | 'value' => ''
|
| | | ),
|
| | | 'limit_database' => array (
|
| | | 'datatype' => 'INTEGER',
|
| | | 'formtype' => 'TEXT',
|
| | |
| | | 'cols' => ''
|
| | | ),
|
| | | ##################################
|
| | | # ENDE Datatable fields
|
| | | # END Datatable fields
|
| | | ##################################
|
| | | )
|
| | | );
|
| | |
|
| | | $form["tabs"]['users'] = array (
|
| | | 'title' => "CP Users",
|
| | | 'width' => 100,
|
| | | 'template' => "templates/reseller_edit_users.htm",
|
| | | 'fields' => array (
|
| | | ##################################
|
| | | # Beginn Datatable fields
|
| | | ##################################
|
| | | |
| | | ##################################
|
| | | # ENDE Datatable fields
|
| | | ##################################
|
| | | ),
|
| | | 'plugins' => array ( |
| | | 'cpuser_list' => array (
|
| | | 'class' => 'plugin_listview',
|
| | | 'options' => array('listdef' => 'list/users.list.php')
|
| | | )
|
| | | )
|
| | | );
|
| | |
|
| | | /*
|
| | | $form["tabs"]['ipaddress'] = array (
|
| | | 'title' => "IP Addresses",
|
| | | 'width' => 100,
|
| | | 'template' => "templates/reseller_edit_ipaddress.htm",
|
| | | 'template' => "templates/client_edit_ipaddress.htm",
|
| | | 'fields' => array (
|
| | | ##################################
|
| | | # Beginn Datatable fields
|
| | |
| | | ##################################
|
| | | )
|
| | | );
|
| | |
|
| | | */
|
| | |
|
| | |
|
| | | ?> |