remove unnecessary ternaries (#1027)
* remove unnecessary ternaries * fix: !($id <= 0); * remove ternary
This commit is contained in:
@@ -14,6 +14,9 @@
|
||||
* @package Formfields
|
||||
*
|
||||
*/
|
||||
|
||||
use Froxlor\Settings;
|
||||
|
||||
return array(
|
||||
'admin_add' => array(
|
||||
'title' => $lng['admin']['admin_add'],
|
||||
@@ -37,7 +40,7 @@ return array(
|
||||
'admin_password_suggestion' => array(
|
||||
'next_to_prefix' => $lng['customer']['generated_pwd'].':',
|
||||
'type' => 'text',
|
||||
'visible' => (\Froxlor\Settings::Get('panel.password_regex') == ''),
|
||||
'visible' => (Settings::Get('panel.password_regex') == ''),
|
||||
'value' => \Froxlor\System\Crypt::generatePassword(),
|
||||
'readonly' => true
|
||||
)
|
||||
@@ -55,8 +58,8 @@ return array(
|
||||
'desc' => $lng['usersettings']['api_allowed']['description'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => (\Froxlor\Settings::Get('api.enabled') == '1' ? true : false),
|
||||
'visible' => (\Froxlor\Settings::Get('api.enabled') == '1' ? true : false)
|
||||
'checked' => Settings::Get('api.enabled') == '1',
|
||||
'visible' => Settings::Get('api.enabled') == '1'
|
||||
)
|
||||
)
|
||||
),
|
||||
@@ -183,7 +186,7 @@ return array(
|
||||
'type' => 'textul',
|
||||
'value' => 0,
|
||||
'maxlength' => 9,
|
||||
'visible' => (\Froxlor\Settings::Get('system.mail_quota_enabled') == '1' ? true : false),
|
||||
'visible' => Settings::Get('system.mail_quota_enabled') == '1',
|
||||
'mandatory' => true
|
||||
),
|
||||
'ftps' => array(
|
||||
|
||||
@@ -33,18 +33,18 @@ return array(
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => $result['deactivated'],
|
||||
'visible' => ($result['adminid'] == $userinfo['userid'] ? false : true)
|
||||
'visible' => $result['adminid'] != $userinfo['userid']
|
||||
),
|
||||
'admin_password' => array(
|
||||
'label' => $lng['login']['password'] . ' (' . $lng['panel']['emptyfornochanges'] . ')',
|
||||
'type' => 'password',
|
||||
'autocomplete' => 'off',
|
||||
'visible' => ($result['adminid'] == $userinfo['userid'] ? false : true),
|
||||
'visible' => $result['adminid'] != $userinfo['userid'],
|
||||
'next_to' => [
|
||||
'admin_password_suggestion' => array(
|
||||
'next_to_prefix' => $lng['customer']['generated_pwd'].':',
|
||||
'type' => 'text',
|
||||
'visible' => (\Froxlor\Settings::Get('panel.password_regex') == '' && ($result['adminid'] == $userinfo['userid'] ? false : true)),
|
||||
'visible' => (\Froxlor\Settings::Get('panel.password_regex') == '' && !($result['adminid'] == $userinfo['userid'])),
|
||||
'value' => \Froxlor\System\Crypt::generatePassword(),
|
||||
'readonly' => true
|
||||
)
|
||||
@@ -55,7 +55,7 @@ return array(
|
||||
'type' => 'select',
|
||||
'select_var' => $languages,
|
||||
'selected' => $result['def_language'],
|
||||
'visible' => ($result['adminid'] == $userinfo['userid'] ? false : true)
|
||||
'visible' => $result['adminid'] != $userinfo['userid']
|
||||
),
|
||||
'api_allowed' => array(
|
||||
'label' => $lng['usersettings']['api_allowed']['title'],
|
||||
@@ -63,7 +63,7 @@ return array(
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => $result['api_allowed'],
|
||||
'visible' => (\Froxlor\Settings::Get('api.enabled') == '1' ? true : false)
|
||||
'visible' => \Froxlor\Settings::Get('api.enabled') == '1'
|
||||
)
|
||||
)
|
||||
),
|
||||
@@ -102,7 +102,7 @@ return array(
|
||||
'section_c' => array(
|
||||
'title' => $lng['admin']['servicedata'],
|
||||
'image' => 'icons/user_add.png',
|
||||
'visible' => ($result['adminid'] != $userinfo['userid'] ? true : false),
|
||||
'visible' => $result['adminid'] != $userinfo['userid'],
|
||||
'fields' => array(
|
||||
'ipaddress' => array(
|
||||
'label' => $lng['serversettings']['ipaddress']['title'],
|
||||
@@ -195,7 +195,7 @@ return array(
|
||||
'type' => 'textul',
|
||||
'value' => $result['email_quota'],
|
||||
'maxlength' => 9,
|
||||
'visible' => (\Froxlor\Settings::Get('system.mail_quota_enabled') == '1' ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mail_quota_enabled') == '1',
|
||||
'mandatory' => true
|
||||
),
|
||||
'ftps' => array(
|
||||
|
||||
@@ -71,8 +71,8 @@ return array(
|
||||
'desc' => $lng['usersettings']['api_allowed']['description'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => (\Froxlor\Settings::Get('api.enabled') == '1' ? true : false),
|
||||
'visible' => (\Froxlor\Settings::Get('api.enabled') == '1' ? true : false)
|
||||
'checked' => \Froxlor\Settings::Get('api.enabled') == '1',
|
||||
'visible' => \Froxlor\Settings::Get('api.enabled') == '1'
|
||||
)
|
||||
)
|
||||
),
|
||||
@@ -213,7 +213,7 @@ return array(
|
||||
'type' => 'textul',
|
||||
'value' => 0,
|
||||
'maxlength' => 9,
|
||||
'visible' => (\Froxlor\Settings::Get('system.mail_quota_enabled') == '1' ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mail_quota_enabled') == '1',
|
||||
'mandatory' => true
|
||||
),
|
||||
'email_imap' => array(
|
||||
@@ -250,7 +250,7 @@ return array(
|
||||
'checked' => true
|
||||
),
|
||||
'allowed_phpconfigs' => array(
|
||||
'visible' => (((int) \Froxlor\Settings::Get('system.mod_fcgid') == 1 || (int) \Froxlor\Settings::Get('phpfpm.enabled') == 1) ? true : false),
|
||||
'visible' => (((int) \Froxlor\Settings::Get('system.mod_fcgid') == 1 || (int) \Froxlor\Settings::Get('phpfpm.enabled') == 1)),
|
||||
'label' => $lng['admin']['phpsettings']['title'],
|
||||
'type' => 'checkbox',
|
||||
'values' => $phpconfigs,
|
||||
@@ -271,8 +271,8 @@ return array(
|
||||
'label' => $lng['admin']['dnsenabled'] . '?',
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => (\Froxlor\Settings::Get('system.dnsenabled') == '1' ? true : false),
|
||||
'visible' => (\Froxlor\Settings::Get('system.dnsenabled') == '1' ? true : false)
|
||||
'checked' => \Froxlor\Settings::Get('system.dnsenabled') == '1',
|
||||
'visible' => \Froxlor\Settings::Get('system.dnsenabled') == '1'
|
||||
),
|
||||
'logviewenabled' => array(
|
||||
'label' => $lng['admin']['logviewenabled'] . '?',
|
||||
|
||||
@@ -71,7 +71,7 @@ return array(
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => $result['api_allowed'],
|
||||
'visible' => (\Froxlor\Settings::Get('api.enabled') == '1' ? true : false)
|
||||
'visible' => \Froxlor\Settings::Get('api.enabled') == '1'
|
||||
)
|
||||
)
|
||||
),
|
||||
@@ -225,7 +225,7 @@ return array(
|
||||
'type' => 'textul',
|
||||
'value' => $result['email_quota'],
|
||||
'maxlength' => 9,
|
||||
'visible' => (\Froxlor\Settings::Get('system.mail_quota_enabled') == '1' ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mail_quota_enabled') == '1',
|
||||
'mandatory' => true
|
||||
),
|
||||
'email_imap' => array(
|
||||
@@ -262,7 +262,7 @@ return array(
|
||||
'checked' => $result['phpenabled']
|
||||
),
|
||||
'allowed_phpconfigs' => array(
|
||||
'visible' => (((int) \Froxlor\Settings::Get('system.mod_fcgid') == 1 || (int) \Froxlor\Settings::Get('phpfpm.enabled') == 1) ? true : false),
|
||||
'visible' => (((int) \Froxlor\Settings::Get('system.mod_fcgid') == 1 || (int) \Froxlor\Settings::Get('phpfpm.enabled') == 1)),
|
||||
'label' => $lng['admin']['phpsettings']['title'],
|
||||
'type' => 'checkbox',
|
||||
'values' => $phpconfigs,
|
||||
@@ -280,7 +280,7 @@ return array(
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => $result['dnsenabled'],
|
||||
'visible' => (\Froxlor\Settings::Get('system.dnsenabled') == '1' ? true : false)
|
||||
'visible' => \Froxlor\Settings::Get('system.dnsenabled') == '1'
|
||||
),
|
||||
'logviewenabled' => array(
|
||||
'label' => $lng['admin']['logviewenabled'] . '?',
|
||||
|
||||
@@ -14,6 +14,9 @@
|
||||
* @package Formfields
|
||||
*
|
||||
*/
|
||||
|
||||
use Froxlor\Settings;
|
||||
|
||||
return array(
|
||||
'domain_add' => array(
|
||||
'title' => $lng['admin']['domain_add'],
|
||||
@@ -35,7 +38,7 @@ return array(
|
||||
'mandatory' => true
|
||||
),
|
||||
'adminid' => array(
|
||||
'visible' => ($userinfo['customers_see_all'] == '1' ? true : false),
|
||||
'visible' => $userinfo['customers_see_all'] == '1',
|
||||
'label' => $lng['admin']['admin'],
|
||||
'type' => 'select',
|
||||
'select_var' => $admins,
|
||||
@@ -103,7 +106,7 @@ return array(
|
||||
'selected' => 0
|
||||
),
|
||||
'dkim' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('dkim.use_dkim') == '1' ? true : false),
|
||||
'visible' => Settings::Get('dkim.use_dkim') == '1',
|
||||
'label' => 'DomainKeys',
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
@@ -116,7 +119,7 @@ return array(
|
||||
'image' => 'icons/domain_add.png',
|
||||
'fields' => array(
|
||||
'documentroot' => array(
|
||||
'visible' => ($userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => $userinfo['change_serversettings'] == '1',
|
||||
'label' => 'DocumentRoot',
|
||||
'desc' => $lng['panel']['emptyfordefault'],
|
||||
'type' => 'text'
|
||||
@@ -126,7 +129,7 @@ return array(
|
||||
'desc' => $lng['domains']['ipandport_multi']['description'],
|
||||
'type' => 'checkbox',
|
||||
'values' => $ipsandports,
|
||||
'value' => explode(',', \Froxlor\Settings::Get('system.defaultip')),
|
||||
'value' => explode(',', Settings::Get('system.defaultip')),
|
||||
'is_array' => 1,
|
||||
'mandatory' => true
|
||||
),
|
||||
@@ -135,7 +138,7 @@ return array(
|
||||
'desc' => $lng['admin']['selectserveralias_desc'],
|
||||
'type' => 'select',
|
||||
'select_var' => $serveraliasoptions,
|
||||
'selected' => \Froxlor\Settings::Get('system.domaindefaultalias')
|
||||
'selected' => Settings::Get('system.domaindefaultalias')
|
||||
),
|
||||
'speciallogfile' => array(
|
||||
'label' => $lng['admin']['speciallogfile']['title'],
|
||||
@@ -145,7 +148,7 @@ return array(
|
||||
'checked' => false
|
||||
),
|
||||
'specialsettings' => array(
|
||||
'visible' => ($userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => $userinfo['change_serversettings'] == '1',
|
||||
'label' => $lng['admin']['ownvhostsettings'],
|
||||
'desc' => $lng['serversettings']['default_vhostconf']['description'],
|
||||
'type' => 'textarea',
|
||||
@@ -153,7 +156,7 @@ return array(
|
||||
'rows' => 12
|
||||
),
|
||||
'notryfiles' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.webserver') == 'nginx' && $userinfo['change_serversettings'] == '1'),
|
||||
'visible' => (Settings::Get('system.webserver') == 'nginx' && $userinfo['change_serversettings'] == '1'),
|
||||
'label' => $lng['admin']['notryfiles']['title'],
|
||||
'desc' => $lng['admin']['notryfiles']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -179,17 +182,17 @@ return array(
|
||||
'section_bssl' => array(
|
||||
'title' => $lng['admin']['webserversettings_ssl'],
|
||||
'image' => 'icons/domain_add.png',
|
||||
'visible' => \Froxlor\Settings::Get('system.use_ssl') == '1' ? true : false,
|
||||
'visible' => Settings::Get('system.use_ssl') == '1',
|
||||
'fields' => array(
|
||||
'sslenabled' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports),
|
||||
'label' => $lng['admin']['domain_sslenabled'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => true
|
||||
),
|
||||
'no_ssl_available_info' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports),
|
||||
'label' => 'SSL',
|
||||
'type' => 'label',
|
||||
'value' => $lng['panel']['nosslipsavailable']
|
||||
@@ -199,11 +202,11 @@ return array(
|
||||
'desc' => $lng['domains']['ipandport_ssl_multi']['description'],
|
||||
'type' => 'checkbox',
|
||||
'values' => $ssl_ipsandports,
|
||||
'value' => explode(',', \Froxlor\Settings::Get('system.defaultsslip')),
|
||||
'value' => explode(',', Settings::Get('system.defaultsslip')),
|
||||
'is_array' => 1
|
||||
),
|
||||
'ssl_redirect' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports),
|
||||
'label' => $lng['domains']['ssl_redirect']['title'],
|
||||
'desc' => $lng['domains']['ssl_redirect']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -211,7 +214,7 @@ return array(
|
||||
'checked' => false
|
||||
),
|
||||
'letsencrypt' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.leenabled') == '1' ? (!empty($ssl_ipsandports) ? true : false) : false),
|
||||
'visible' => (Settings::Get('system.leenabled') == '1' && !empty($ssl_ipsandports)),
|
||||
'label' => $lng['admin']['letsencrypt']['title'],
|
||||
'desc' => $lng['admin']['letsencrypt']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -219,7 +222,7 @@ return array(
|
||||
'checked' => false
|
||||
),
|
||||
'http2' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false) && \Froxlor\Settings::Get('system.webserver') != 'lighttpd' && \Froxlor\Settings::Get('system.http2_support') == '1',
|
||||
'visible' => !empty($ssl_ipsandports) && Settings::Get('system.webserver') != 'lighttpd' && Settings::Get('system.http2_support') == '1',
|
||||
'label' => $lng['admin']['domain_http2']['title'],
|
||||
'desc' => $lng['admin']['domain_http2']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -227,14 +230,14 @@ return array(
|
||||
'checked' => false
|
||||
),
|
||||
'override_tls' => array(
|
||||
'visible' => ((!empty($ssl_ipsandports) ? true : false) && $userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports) && $userinfo['change_serversettings'] == '1',
|
||||
'label' => $lng['admin']['domain_override_tls'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => false
|
||||
),
|
||||
'ssl_protocols' => array(
|
||||
'visible' => ((!empty($ssl_ipsandports) ? true : false) && $userinfo['change_serversettings'] == '1' && \Froxlor\Settings::Get('system.webserver') != 'lighttpd' ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports) && $userinfo['change_serversettings'] == '1' && Settings::Get('system.webserver') != 'lighttpd',
|
||||
'label' => $lng['serversettings']['ssl']['ssl_protocols']['title'],
|
||||
'desc' => $lng['serversettings']['ssl']['ssl_protocols']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -262,21 +265,21 @@ return array(
|
||||
'is_array' => 1
|
||||
),
|
||||
'ssl_cipher_list' => array(
|
||||
'visible' => ((!empty($ssl_ipsandports) ? true : false) && $userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports) && $userinfo['change_serversettings'] == '1',
|
||||
'label' => $lng['serversettings']['ssl']['ssl_cipher_list']['title'],
|
||||
'desc' => $lng['serversettings']['ssl']['ssl_cipher_list']['description'],
|
||||
'type' => 'text',
|
||||
'value' => \Froxlor\Settings::Get('system.ssl_cipher_list')
|
||||
'value' => Settings::Get('system.ssl_cipher_list')
|
||||
),
|
||||
'tlsv13_cipher_list' => array(
|
||||
'visible' => ((!empty($ssl_ipsandports) ? true : false) && $userinfo['change_serversettings'] == '1' && \Froxlor\Settings::Get('system.webserver') == "apache2" && \Froxlor\Settings::Get('system.apache24') == 1 ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports) && $userinfo['change_serversettings'] == '1' && Settings::Get('system.webserver') == "apache2" && Settings::Get('system.apache24') == 1,
|
||||
'label' => $lng['serversettings']['ssl']['tlsv13_cipher_list']['title'],
|
||||
'desc' => $lng['serversettings']['ssl']['tlsv13_cipher_list']['description'],
|
||||
'type' => 'text',
|
||||
'value' => \Froxlor\Settings::Get('system.tlsv13_cipher_list')
|
||||
'value' => Settings::Get('system.tlsv13_cipher_list')
|
||||
),
|
||||
'ssl_specialsettings' => array(
|
||||
'visible' => ((!empty($ssl_ipsandports) ? true : false) && $userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports) && $userinfo['change_serversettings'] == '1',
|
||||
'label' => $lng['admin']['ownsslvhostsettings'],
|
||||
'desc' => $lng['serversettings']['default_vhostconf']['description'],
|
||||
'type' => 'textarea',
|
||||
@@ -284,14 +287,14 @@ return array(
|
||||
'rows' => 12
|
||||
),
|
||||
'include_specialsettings' => array(
|
||||
'visible' => ((!empty($ssl_ipsandports) ? true : false) && $userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports) && $userinfo['change_serversettings'] == '1',
|
||||
'label' => $lng['admin']['include_ownvhostsettings'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => false
|
||||
),
|
||||
'hsts_maxage' => array(
|
||||
'visible' => ($ssl_ipsandports != '' ? true : false),
|
||||
'visible' => $ssl_ipsandports != '',
|
||||
'label' => $lng['admin']['domain_hsts_maxage']['title'],
|
||||
'desc' => $lng['admin']['domain_hsts_maxage']['description'],
|
||||
'type' => 'number',
|
||||
@@ -300,7 +303,7 @@ return array(
|
||||
'value' => 0
|
||||
),
|
||||
'hsts_sub' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports),
|
||||
'label' => $lng['admin']['domain_hsts_incsub']['title'],
|
||||
'desc' => $lng['admin']['domain_hsts_incsub']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -308,7 +311,7 @@ return array(
|
||||
'checked' => false
|
||||
),
|
||||
'hsts_preload' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports),
|
||||
'label' => $lng['admin']['domain_hsts_preload']['title'],
|
||||
'desc' => $lng['admin']['domain_hsts_preload']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -316,22 +319,22 @@ return array(
|
||||
'checked' => false
|
||||
),
|
||||
'ocsp_stapling' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false) && \Froxlor\Settings::Get('system.webserver') != 'lighttpd',
|
||||
'visible' => !empty($ssl_ipsandports) && Settings::Get('system.webserver') != 'lighttpd',
|
||||
'label' => $lng['admin']['domain_ocsp_stapling']['title'],
|
||||
'desc' => $lng['admin']['domain_ocsp_stapling']['description'] . (\Froxlor\Settings::Get('system.webserver') == 'nginx' ? $lng['admin']['domain_ocsp_stapling']['nginx_version_warning'] : ""),
|
||||
'desc' => $lng['admin']['domain_ocsp_stapling']['description'] . (Settings::Get('system.webserver') == 'nginx' ? $lng['admin']['domain_ocsp_stapling']['nginx_version_warning'] : ""),
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => false
|
||||
),
|
||||
'honorcipherorder' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports),
|
||||
'label' => $lng['admin']['domain_honorcipherorder'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => false
|
||||
),
|
||||
'sessiontickets' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false) && \Froxlor\Settings::Get('system.webserver') != 'lighttpd' && \Froxlor\Settings::Get('system.sessionticketsenabled' != '1'),
|
||||
'visible' => !empty($ssl_ipsandports) && Settings::Get('system.webserver') != 'lighttpd' && Settings::Get('system.sessionticketsenabled' != '1'),
|
||||
'label' => $lng['admin']['domain_sessiontickets'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
@@ -342,7 +345,7 @@ return array(
|
||||
'section_c' => array(
|
||||
'title' => $lng['admin']['phpserversettings'],
|
||||
'image' => 'icons/domain_add.png',
|
||||
'visible' => (($userinfo['change_serversettings'] == '1' || $userinfo['caneditphpsettings'] == '1') ? true : false),
|
||||
'visible' => $userinfo['change_serversettings'] == '1' || $userinfo['caneditphpsettings'] == '1',
|
||||
'fields' => array(
|
||||
'openbasedir' => array(
|
||||
'label' => 'OpenBasedir',
|
||||
@@ -357,19 +360,19 @@ return array(
|
||||
'checked' => true
|
||||
),
|
||||
'phpsettingid' => array(
|
||||
'visible' => (((int) \Froxlor\Settings::Get('system.mod_fcgid') == 1 || (int) \Froxlor\Settings::Get('phpfpm.enabled') == 1) ? true : false),
|
||||
'visible' => (int) Settings::Get('system.mod_fcgid') == 1 || (int) Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['title'],
|
||||
'type' => 'select',
|
||||
'select_var' => $phpconfigs,
|
||||
'selected' => (int) \Froxlor\Settings::Get('phpfpm.enabled') == 1 ? \Froxlor\Settings::Get('phpfpm.defaultini') : \Froxlor\Settings::Get('system.mod_fcgid_defaultini')
|
||||
'selected' => (int) Settings::Get('phpfpm.enabled') == 1 ? Settings::Get('phpfpm.defaultini') : Settings::Get('system.mod_fcgid_defaultini')
|
||||
),
|
||||
'mod_fcgid_starter' => array(
|
||||
'visible' => ((int) \Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => (int) Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['mod_fcgid_starter']['title'],
|
||||
'type' => 'number'
|
||||
),
|
||||
'mod_fcgid_maxrequests' => array(
|
||||
'visible' => ((int) \Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => (int) Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['mod_fcgid_maxrequests']['title'],
|
||||
'type' => 'number'
|
||||
)
|
||||
@@ -378,7 +381,7 @@ return array(
|
||||
'section_d' => array(
|
||||
'title' => $lng['admin']['nameserversettings'],
|
||||
'image' => 'icons/domain_add.png',
|
||||
'visible' => (\Froxlor\Settings::Get('system.bind_enable') == '1' && $userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => Settings::Get('system.bind_enable') == '1' && $userinfo['change_serversettings'] == '1',
|
||||
'fields' => array(
|
||||
'isbinddomain' => array(
|
||||
'label' => 'Nameserver',
|
||||
|
||||
@@ -37,7 +37,7 @@ return array(
|
||||
'mandatory' => true
|
||||
),
|
||||
'adminid' => array(
|
||||
'visible' => ($userinfo['customers_see_all'] == '1' ? true : false),
|
||||
'visible' => $userinfo['customers_see_all'] == '1',
|
||||
'label' => $lng['admin']['admin'],
|
||||
'type' => (\Froxlor\Settings::Get('panel.allow_domain_change_admin') == '1' ? 'select' : 'infotext'),
|
||||
'select_var' => (!empty($admins) ? $admins : null),
|
||||
@@ -46,7 +46,7 @@ return array(
|
||||
'mandatory' => true
|
||||
),
|
||||
'alias' => array(
|
||||
'visible' => ($alias_check == '0' ? true : false),
|
||||
'visible' => $alias_check == '0',
|
||||
'label' => $lng['domains']['aliasdomain'],
|
||||
'type' => 'select',
|
||||
'select_var' => $domains,
|
||||
@@ -116,7 +116,7 @@ return array(
|
||||
'selected' => $result['subcanemaildomain']
|
||||
),
|
||||
'dkim' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('dkim.use_dkim') == '1' ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('dkim.use_dkim') == '1',
|
||||
'label' => 'DomainKeys',
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
@@ -129,7 +129,7 @@ return array(
|
||||
'image' => 'icons/domain_edit.png',
|
||||
'fields' => array(
|
||||
'documentroot' => array(
|
||||
'visible' => ($userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => $userinfo['change_serversettings'] == '1',
|
||||
'label' => 'DocumentRoot',
|
||||
'desc' => $lng['panel']['emptyfordefault'],
|
||||
'type' => 'text',
|
||||
@@ -163,7 +163,7 @@ return array(
|
||||
'value' => '0'
|
||||
),
|
||||
'specialsettings' => array(
|
||||
'visible' => ($userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => $userinfo['change_serversettings'] == '1',
|
||||
'label' => $lng['admin']['ownvhostsettings'],
|
||||
'desc' => $lng['serversettings']['default_vhostconf']['description'],
|
||||
'type' => 'textarea',
|
||||
@@ -172,7 +172,7 @@ return array(
|
||||
'rows' => 12
|
||||
),
|
||||
'specialsettingsforsubdomains' => array(
|
||||
'visible' => ($userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => $userinfo['change_serversettings'] == '1',
|
||||
'label' => $lng['admin']['specialsettingsforsubdomains'],
|
||||
'desc' => $lng['serversettings']['specialsettingsforsubdomains']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -206,17 +206,17 @@ return array(
|
||||
'section_bssl' => array(
|
||||
'title' => $lng['admin']['webserversettings_ssl'],
|
||||
'image' => 'icons/domain_edit.png',
|
||||
'visible' => \Froxlor\Settings::Get('system.use_ssl') == '1' ? true : false,
|
||||
'visible' => \Froxlor\Settings::Get('system.use_ssl') == '1',
|
||||
'fields' => array(
|
||||
'sslenabled' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports),
|
||||
'label' => $lng['admin']['domain_sslenabled'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => $result['ssl_enabled']
|
||||
),
|
||||
'no_ssl_available_info' => array(
|
||||
'visible' => (empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => empty($ssl_ipsandports),
|
||||
'label' => 'SSL',
|
||||
'type' => 'label',
|
||||
'value' => $lng['panel']['nosslipsavailable']
|
||||
@@ -230,7 +230,7 @@ return array(
|
||||
'is_array' => 1
|
||||
),
|
||||
'ssl_redirect' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports),
|
||||
'label' => $lng['domains']['ssl_redirect']['title'],
|
||||
'desc' => $lng['domains']['ssl_redirect']['description'] . ($result['temporary_ssl_redirect'] > 1 ? $lng['domains']['ssl_redirect_temporarilydisabled'] : ''),
|
||||
'type' => 'checkbox',
|
||||
@@ -238,7 +238,7 @@ return array(
|
||||
'checked' => $result['ssl_redirect']
|
||||
),
|
||||
'letsencrypt' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.leenabled') == '1' ? (!empty($ssl_ipsandports) ? true : false) : false),
|
||||
'visible' => (\Froxlor\Settings::Get('system.leenabled') == '1' && !empty($ssl_ipsandports)),
|
||||
'label' => $lng['admin']['letsencrypt']['title'],
|
||||
'desc' => $lng['admin']['letsencrypt']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -246,7 +246,7 @@ return array(
|
||||
'checked' => $result['letsencrypt']
|
||||
),
|
||||
'http2' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false) && \Froxlor\Settings::Get('system.webserver') != 'lighttpd' && \Froxlor\Settings::Get('system.http2_support') == '1',
|
||||
'visible' => !empty($ssl_ipsandports) && \Froxlor\Settings::Get('system.webserver') != 'lighttpd' && \Froxlor\Settings::Get('system.http2_support') == '1',
|
||||
'label' => $lng['admin']['domain_http2']['title'],
|
||||
'desc' => $lng['admin']['domain_http2']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -254,14 +254,14 @@ return array(
|
||||
'checked' => $result['http2']
|
||||
),
|
||||
'override_tls' => array(
|
||||
'visible' => ((!empty($ssl_ipsandports) ? true : false) && $userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports) && $userinfo['change_serversettings'] == '1',
|
||||
'label' => $lng['admin']['domain_override_tls'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => $result['override_tls']
|
||||
),
|
||||
'ssl_protocols' => array(
|
||||
'visible' => ((!empty($ssl_ipsandports) ? true : false) && $userinfo['change_serversettings'] == '1' && \Froxlor\Settings::Get('system.webserver') != 'lighttpd' ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports) && $userinfo['change_serversettings'] == '1' && \Froxlor\Settings::Get('system.webserver') != 'lighttpd',
|
||||
'label' => $lng['serversettings']['ssl']['ssl_protocols']['title'],
|
||||
'desc' => $lng['serversettings']['ssl']['ssl_protocols']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -287,21 +287,21 @@ return array(
|
||||
'is_array' => 1
|
||||
),
|
||||
'ssl_cipher_list' => array(
|
||||
'visible' => ((!empty($ssl_ipsandports) ? true : false) && $userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports) && $userinfo['change_serversettings'] == '1',
|
||||
'label' => $lng['serversettings']['ssl']['ssl_cipher_list']['title'],
|
||||
'desc' => $lng['serversettings']['ssl']['ssl_cipher_list']['description'],
|
||||
'type' => 'text',
|
||||
'value' => !empty($result['ssl_cipher_list']) ? $result['ssl_cipher_list'] : \Froxlor\Settings::Get('system.ssl_cipher_list')
|
||||
),
|
||||
'tlsv13_cipher_list' => array(
|
||||
'visible' => ((!empty($ssl_ipsandports) ? true : false) && $userinfo['change_serversettings'] == '1' && \Froxlor\Settings::Get('system.webserver') == "apache2" && \Froxlor\Settings::Get('system.apache24') == 1 ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports) && $userinfo['change_serversettings'] == '1' && \Froxlor\Settings::Get('system.webserver') == "apache2" && \Froxlor\Settings::Get('system.apache24') == 1,
|
||||
'label' => $lng['serversettings']['ssl']['tlsv13_cipher_list']['title'],
|
||||
'desc' => $lng['serversettings']['ssl']['tlsv13_cipher_list']['description'],
|
||||
'type' => 'text',
|
||||
'value' => !empty($result['tlsv13_cipher_list']) ? $result['tlsv13_cipher_list'] : \Froxlor\Settings::Get('system.tlsv13_cipher_list')
|
||||
),
|
||||
'ssl_specialsettings' => array(
|
||||
'visible' => ($userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => $userinfo['change_serversettings'] == '1',
|
||||
'label' => $lng['admin']['ownsslvhostsettings'],
|
||||
'desc' => $lng['serversettings']['default_vhostconf']['description'],
|
||||
'type' => 'textarea',
|
||||
@@ -316,7 +316,7 @@ return array(
|
||||
'checked' => $result['include_specialsettings']
|
||||
),
|
||||
'hsts_maxage' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports),
|
||||
'label' => $lng['admin']['domain_hsts_maxage']['title'],
|
||||
'desc' => $lng['admin']['domain_hsts_maxage']['description'],
|
||||
'type' => 'number',
|
||||
@@ -325,7 +325,7 @@ return array(
|
||||
'value' => $result['hsts']
|
||||
),
|
||||
'hsts_sub' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports),
|
||||
'label' => $lng['admin']['domain_hsts_incsub']['title'],
|
||||
'desc' => $lng['admin']['domain_hsts_incsub']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -333,7 +333,7 @@ return array(
|
||||
'checked' => $result['hsts_sub']
|
||||
),
|
||||
'hsts_preload' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports),
|
||||
'label' => $lng['admin']['domain_hsts_preload']['title'],
|
||||
'desc' => $lng['admin']['domain_hsts_preload']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -341,7 +341,7 @@ return array(
|
||||
'checked' => $result['hsts_preload']
|
||||
),
|
||||
'ocsp_stapling' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false) && \Froxlor\Settings::Get('system.webserver') != 'lighttpd',
|
||||
'visible' => !empty($ssl_ipsandports) && \Froxlor\Settings::Get('system.webserver') != 'lighttpd',
|
||||
'label' => $lng['admin']['domain_ocsp_stapling']['title'],
|
||||
'desc' => $lng['admin']['domain_ocsp_stapling']['description'] . (\Froxlor\Settings::Get('system.webserver') == 'nginx' ? $lng['admin']['domain_ocsp_stapling']['nginx_version_warning'] : ""),
|
||||
'type' => 'checkbox',
|
||||
@@ -349,14 +349,14 @@ return array(
|
||||
'checked' => $result['ocsp_stapling']
|
||||
),
|
||||
'honorcipherorder' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false),
|
||||
'visible' => !empty($ssl_ipsandports),
|
||||
'label' => $lng['admin']['domain_honorcipherorder'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => $result['ssl_honorcipherorder']
|
||||
),
|
||||
'sessiontickets' => array(
|
||||
'visible' => (!empty($ssl_ipsandports) ? true : false) && \Froxlor\Settings::Get('system.webserver') != 'lighttpd' && \Froxlor\Settings::Get('system.sessionticketsenabled' != '1'),
|
||||
'visible' => !empty($ssl_ipsandports) && \Froxlor\Settings::Get('system.webserver') != 'lighttpd' && \Froxlor\Settings::Get('system.sessionticketsenabled' != '1'),
|
||||
'label' => $lng['admin']['domain_sessiontickets'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
@@ -367,7 +367,7 @@ return array(
|
||||
'section_c' => array(
|
||||
'title' => $lng['admin']['phpserversettings'],
|
||||
'image' => 'icons/domain_edit.png',
|
||||
'visible' => (($userinfo['change_serversettings'] == '1' || $userinfo['caneditphpsettings'] == '1') ? true : false),
|
||||
'visible' => $userinfo['change_serversettings'] == '1' || $userinfo['caneditphpsettings'] == '1',
|
||||
'fields' => array(
|
||||
'openbasedir' => array(
|
||||
'label' => 'OpenBasedir',
|
||||
@@ -382,14 +382,14 @@ return array(
|
||||
'checked' => $result['phpenabled']
|
||||
),
|
||||
'phpsettingid' => array(
|
||||
'visible' => (((int) \Froxlor\Settings::Get('system.mod_fcgid') == 1 || (int) \Froxlor\Settings::Get('phpfpm.enabled') == 1) ? true : false),
|
||||
'visible' => (((int) \Froxlor\Settings::Get('system.mod_fcgid') == 1 || (int) \Froxlor\Settings::Get('phpfpm.enabled') == 1)),
|
||||
'label' => $lng['admin']['phpsettings']['title'],
|
||||
'type' => 'select',
|
||||
'select_var' => $phpconfigs,
|
||||
'selected' => $result['phpsettingid']
|
||||
),
|
||||
'phpsettingsforsubdomains' => array(
|
||||
'visible' => ($userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => $userinfo['change_serversettings'] == '1',
|
||||
'label' => $lng['admin']['phpsettingsforsubdomains'],
|
||||
'desc' => $lng['serversettings']['phpsettingsforsubdomains']['description'],
|
||||
'type' => 'checkbox',
|
||||
@@ -397,13 +397,13 @@ return array(
|
||||
'checked' => \Froxlor\Settings::Get('system.apply_phpconfigs_default') == 1 ? '1' : '0'
|
||||
),
|
||||
'mod_fcgid_starter' => array(
|
||||
'visible' => ((int) \Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => (int) \Froxlor\Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['mod_fcgid_starter']['title'],
|
||||
'type' => 'number',
|
||||
'value' => ((int) $result['mod_fcgid_starter'] != -1 ? $result['mod_fcgid_starter'] : '')
|
||||
),
|
||||
'mod_fcgid_maxrequests' => array(
|
||||
'visible' => ((int) \Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => (int) \Froxlor\Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['mod_fcgid_maxrequests']['title'],
|
||||
'type' => 'number',
|
||||
'value' => ((int) $result['mod_fcgid_maxrequests'] != -1 ? $result['mod_fcgid_maxrequests'] : '')
|
||||
@@ -413,7 +413,7 @@ return array(
|
||||
'section_d' => array(
|
||||
'title' => $lng['admin']['nameserversettings'],
|
||||
'image' => 'icons/domain_edit.png',
|
||||
'visible' => (\Froxlor\Settings::Get('system.bind_enable') == '1' && $userinfo['change_serversettings'] == '1' ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.bind_enable') == '1' && $userinfo['change_serversettings'] == '1',
|
||||
'fields' => array(
|
||||
'isbinddomain' => array(
|
||||
'label' => 'Nameserver',
|
||||
|
||||
@@ -54,7 +54,7 @@ return array(
|
||||
'label' => $lng['admin']['ipsandports']['create_namevirtualhost_statement'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => \Froxlor\Settings::Get('system.webserver') == 'apache2' && (int) \Froxlor\Settings::Get('system.apache24') == 0 ? true : false
|
||||
'checked' => \Froxlor\Settings::Get('system.webserver') == 'apache2' && (int) \Froxlor\Settings::Get('system.apache24') == 0
|
||||
),
|
||||
'vhostcontainer' => array(
|
||||
'label' => $lng['admin']['ipsandports']['create_vhostcontainer'],
|
||||
@@ -95,7 +95,7 @@ return array(
|
||||
'rows' => 12
|
||||
),
|
||||
'ssl_default_vhostconf_domain' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.use_ssl') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.use_ssl') == 1,
|
||||
'label' => $lng['admin']['ipsandports']['ssl_default_vhostconf_domain'],
|
||||
'desc' => $lng['serversettings']['default_vhostconf_domain']['description'],
|
||||
'type' => 'textarea',
|
||||
@@ -113,7 +113,7 @@ return array(
|
||||
'section_d' => array(
|
||||
'title' => $lng['admin']['ipsandports']['webserverssldomainconfig'],
|
||||
'image' => 'icons/ipsports_add.png',
|
||||
'visible' => (\Froxlor\Settings::Get('system.use_ssl') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.use_ssl') == 1,
|
||||
'fields' => array(
|
||||
'ssl' => array(
|
||||
'label' => $lng['admin']['ipsandports']['enable_ssl'],
|
||||
|
||||
@@ -99,7 +99,7 @@ return array(
|
||||
'value' => $result['default_vhostconf_domain']
|
||||
),
|
||||
'ssl_default_vhostconf_domain' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.use_ssl') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.use_ssl') == 1,
|
||||
'label' => $lng['admin']['ipsandports']['ssl_default_vhostconf_domain'],
|
||||
'desc' => $lng['serversettings']['default_vhostconf_domain']['description'],
|
||||
'type' => 'textarea',
|
||||
@@ -118,7 +118,7 @@ return array(
|
||||
'section_d' => array(
|
||||
'title' => $lng['admin']['ipsandports']['webserverssldomainconfig'],
|
||||
'image' => 'icons/ipsports_edit.png',
|
||||
'visible' => (\Froxlor\Settings::Get('system.use_ssl') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.use_ssl') == 1,
|
||||
'fields' => array(
|
||||
'ssl' => array(
|
||||
'label' => $lng['admin']['ipsandports']['enable_ssl'],
|
||||
|
||||
@@ -29,21 +29,21 @@ return array(
|
||||
'maxlength' => 50
|
||||
),
|
||||
'binary' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['binary'],
|
||||
'type' => 'text',
|
||||
'maxlength' => 255,
|
||||
'value' => '/usr/bin/php-cgi'
|
||||
),
|
||||
'fpmconfig' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['fpmdesc'],
|
||||
'type' => 'select',
|
||||
'select_var' => $fpmconfigs,
|
||||
'selected' => 1
|
||||
),
|
||||
'file_extensions' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['file_extensions'],
|
||||
'desc' => $lng['admin']['phpsettings']['file_extensions_note'],
|
||||
'type' => 'text',
|
||||
@@ -51,59 +51,59 @@ return array(
|
||||
'value' => 'php'
|
||||
),
|
||||
'mod_fcgid_starter' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['mod_fcgid_starter']['title'],
|
||||
'type' => 'number'
|
||||
),
|
||||
'mod_fcgid_maxrequests' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['mod_fcgid_maxrequests']['title'],
|
||||
'type' => 'number'
|
||||
),
|
||||
'mod_fcgid_umask' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['mod_fcgid_umask']['title'],
|
||||
'type' => 'text',
|
||||
'maxlength' => 3,
|
||||
'value' => '022'
|
||||
),
|
||||
'phpfpm_enable_slowlog' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['enable_slowlog'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => false
|
||||
),
|
||||
'phpfpm_reqtermtimeout' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['request_terminate_timeout'],
|
||||
'type' => 'text',
|
||||
'maxlength' => 10,
|
||||
'value' => '60s'
|
||||
),
|
||||
'phpfpm_reqslowtimeout' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['request_slowlog_timeout'],
|
||||
'type' => 'text',
|
||||
'maxlength' => 10,
|
||||
'value' => '5s'
|
||||
),
|
||||
'phpfpm_pass_authorizationheader' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['pass_authorizationheader'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => false
|
||||
),
|
||||
'override_fpmconfig' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['override_fpmconfig'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => false
|
||||
),
|
||||
'pm' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['pm'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'select',
|
||||
@@ -114,49 +114,49 @@ return array(
|
||||
]
|
||||
),
|
||||
'max_children' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['max_children']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['max_children']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'number',
|
||||
'value' => 1
|
||||
),
|
||||
'start_servers' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['start_servers']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['start_servers']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'number',
|
||||
'value' => 20
|
||||
),
|
||||
'min_spare_servers' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['min_spare_servers']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['min_spare_servers']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'number',
|
||||
'value' => 5
|
||||
),
|
||||
'max_spare_servers' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['max_spare_servers']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['max_spare_servers']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'number',
|
||||
'value' => 35
|
||||
),
|
||||
'max_requests' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['max_requests']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['max_requests']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'number',
|
||||
'value' => 0
|
||||
),
|
||||
'idle_timeout' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['idle_timeout']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['idle_timeout']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'number',
|
||||
'value' => 10
|
||||
),
|
||||
'limit_extensions' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['limit_extensions']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['limit_extensions']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'text',
|
||||
|
||||
@@ -30,21 +30,21 @@ return array(
|
||||
'value' => $result['description']
|
||||
),
|
||||
'binary' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['binary'],
|
||||
'type' => 'text',
|
||||
'maxlength' => 255,
|
||||
'value' => $result['binary']
|
||||
),
|
||||
'fpmconfig' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['fpmdesc'],
|
||||
'type' => 'select',
|
||||
'select_var' => $fpmconfigs,
|
||||
'selected' => $result['fpmsettingid']
|
||||
),
|
||||
'file_extensions' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['file_extensions'],
|
||||
'desc' => $lng['admin']['phpsettings']['file_extensions_note'],
|
||||
'type' => 'text',
|
||||
@@ -52,47 +52,47 @@ return array(
|
||||
'value' => $result['file_extensions']
|
||||
),
|
||||
'mod_fcgid_starter' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['mod_fcgid_starter']['title'],
|
||||
'type' => 'number',
|
||||
'value' => ((int) $result['mod_fcgid_starter'] != -1 ? $result['mod_fcgid_starter'] : '')
|
||||
),
|
||||
'mod_fcgid_maxrequests' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['mod_fcgid_maxrequests']['title'],
|
||||
'type' => 'number',
|
||||
'value' => ((int) $result['mod_fcgid_maxrequests'] != -1 ? $result['mod_fcgid_maxrequests'] : '')
|
||||
),
|
||||
'mod_fcgid_umask' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('system.mod_fcgid') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('system.mod_fcgid') == 1,
|
||||
'label' => $lng['admin']['mod_fcgid_umask']['title'],
|
||||
'type' => 'text',
|
||||
'maxlength' => 3,
|
||||
'value' => $result['mod_fcgid_umask']
|
||||
),
|
||||
'phpfpm_enable_slowlog' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['enable_slowlog'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
'checked' => $result['fpm_slowlog']
|
||||
),
|
||||
'phpfpm_reqtermtimeout' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['request_terminate_timeout'],
|
||||
'type' => 'text',
|
||||
'maxlength' => 10,
|
||||
'value' => $result['fpm_reqterm']
|
||||
),
|
||||
'phpfpm_reqslowtimeout' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['request_slowlog_timeout'],
|
||||
'type' => 'text',
|
||||
'maxlength' => 10,
|
||||
'value' => $result['fpm_reqslow']
|
||||
),
|
||||
'phpfpm_pass_authorizationheader' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['admin']['phpsettings']['pass_authorizationheader'],
|
||||
'type' => 'checkbox',
|
||||
'value' => '1',
|
||||
@@ -105,7 +105,7 @@ return array(
|
||||
'checked' => $result['override_fpmconfig']
|
||||
),
|
||||
'pm' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['pm'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'select',
|
||||
@@ -117,49 +117,49 @@ return array(
|
||||
'selected' => $result['pm']
|
||||
),
|
||||
'max_children' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['max_children']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['max_children']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'number',
|
||||
'value' => $result['max_children']
|
||||
),
|
||||
'start_servers' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['start_servers']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['start_servers']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'number',
|
||||
'value' => $result['start_servers']
|
||||
),
|
||||
'min_spare_servers' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['min_spare_servers']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['min_spare_servers']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'number',
|
||||
'value' => $result['min_spare_servers']
|
||||
),
|
||||
'max_spare_servers' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['max_spare_servers']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['max_spare_servers']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'number',
|
||||
'value' => $result['max_spare_servers']
|
||||
),
|
||||
'max_requests' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['max_requests']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['max_requests']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'number',
|
||||
'value' => $result['max_requests']
|
||||
),
|
||||
'idle_timeout' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['idle_timeout']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['idle_timeout']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'number',
|
||||
'value' => $result['idle_timeout']
|
||||
),
|
||||
'limit_extensions' => array(
|
||||
'visible' => (\Froxlor\Settings::Get('phpfpm.enabled') == 1 ? true : false),
|
||||
'visible' => \Froxlor\Settings::Get('phpfpm.enabled') == 1,
|
||||
'label' => $lng['serversettings']['phpfpm_settings']['limit_extensions']['title'],
|
||||
'desc' => $lng['serversettings']['phpfpm_settings']['limit_extensions']['description'] . $lng['serversettings']['phpfpm_settings']['override_fpmconfig_addinfo'],
|
||||
'type' => 'text',
|
||||
|
||||
Reference in New Issue
Block a user