|
16 | 16 | //if ($_SESSION['user'] == 'admin') { |
17 | 17 | // Mail Domain |
18 | 18 | if (!empty($_POST['ok'])) { |
19 | | - if (empty($_POST['v_domain'])) $errors[] = _('domain'); |
| 19 | + if (empty($_POST['v_domain'])) $errors[] = __('domain'); |
20 | 20 | if (!empty($_POST['v_antispam'])) { |
21 | 21 | $v_antispam = 'yes'; |
22 | 22 | } else { |
|
48 | 48 | $error_msg = $error_msg.", ".$error; |
49 | 49 | } |
50 | 50 | } |
51 | | - $_SESSION['error_msg'] = _('Field "%s" can not be blank.',$error_msg); |
| 51 | + $_SESSION['error_msg'] = __('Field "%s" can not be blank.',$error_msg); |
52 | 52 | } else { |
53 | 53 |
|
54 | 54 | // Add mail domain |
55 | 55 | exec (VESTA_CMD."v-add-mail-domain ".$user." ".$v_domain." ".$v_antispam." ".$v_antivirus." ".$v_dkim, $output, $return_var); |
56 | 56 | if ($return_var != 0) { |
57 | 57 | $error = implode('<br>', $output); |
58 | | - if (empty($error)) $error = _('Error code:',$return_var); |
| 58 | + if (empty($error)) $error = __('Error code:',$return_var); |
59 | 59 | $_SESSION['error_msg'] = $error; |
60 | 60 | } |
61 | 61 | unset($output); |
62 | 62 |
|
63 | 63 | if (empty($_SESSION['error_msg'])) { |
64 | | - $_SESSION['ok_msg'] = _('MAIL_DOMAIN_CREATED_OK',$_POST['v_domain'],$_POST['v_domain']); |
| 64 | + $_SESSION['ok_msg'] = __('MAIL_DOMAIN_CREATED_OK',$_POST['v_domain'],$_POST['v_domain']); |
65 | 65 | unset($v_domain); |
66 | 66 | } |
67 | 67 | } |
|
71 | 71 | // Mail Account |
72 | 72 | if (!empty($_POST['ok_acc'])) { |
73 | 73 | // Check input |
74 | | - if (empty($_POST['v_domain'])) $errors[] = _('domain'); |
75 | | - if (empty($_POST['v_account'])) $errors[] = _('account'); |
76 | | - if (empty($_POST['v_password'])) $errors[] = _('password'); |
| 74 | + if (empty($_POST['v_domain'])) $errors[] = __('domain'); |
| 75 | + if (empty($_POST['v_account'])) $errors[] = __('account'); |
| 76 | + if (empty($_POST['v_password'])) $errors[] = __('password'); |
77 | 77 |
|
78 | 78 | // Protect input |
79 | 79 | $v_domain = escapeshellarg($_POST['v_domain']); |
|
95 | 95 | $error_msg = $error_msg.", ".$error; |
96 | 96 | } |
97 | 97 | } |
98 | | - $_SESSION['error_msg'] = _('Field "%s" can not be blank.',$error_msg); |
| 98 | + $_SESSION['error_msg'] = __('Field "%s" can not be blank.',$error_msg); |
99 | 99 | } else { |
100 | 100 | // Add Mail Account |
101 | 101 | exec (VESTA_CMD."v-add-mail-account ".$user." ".$v_domain." ".$v_account." ".$v_password." ".$v_quota, $output, $return_var); |
102 | 102 | if ($return_var != 0) { |
103 | 103 | $error = implode('<br>', $output); |
104 | | - if (empty($error)) $error = _('Error code:',$return_var); |
| 104 | + if (empty($error)) $error = __('Error code:',$return_var); |
105 | 105 | $_SESSION['error_msg'] = $error; |
106 | 106 | } |
107 | 107 |
|
|
118 | 118 | exec (VESTA_CMD."v-add-mail-account-alias ".$user." ".$v_domain." ".$v_account." ".$alias, $output, $return_var); |
119 | 119 | if ($return_var != 0) { |
120 | 120 | $error = implode('<br>', $output); |
121 | | - if (empty($error)) $error = _('Error: vesta did not return any output.'); |
| 121 | + if (empty($error)) $error = __('Error: vesta did not return any output.'); |
122 | 122 | $_SESSION['error_msg'] = $error; |
123 | 123 | } |
124 | 124 | } |
|
139 | 139 | exec (VESTA_CMD."v-add-mail-account-forward ".$user." ".$v_domain." ".$v_account." ".$forward, $output, $return_var); |
140 | 140 | if ($return_var != 0) { |
141 | 141 | $error = implode('<br>', $output); |
142 | | - if (empty($error)) $error = _('Error: vesta did not return any output.'); |
| 142 | + if (empty($error)) $error = __('Error: vesta did not return any output.'); |
143 | 143 | $_SESSION['error_msg'] = $error; |
144 | 144 | } |
145 | 145 | } |
|
149 | 149 |
|
150 | 150 | unset($output); |
151 | 151 | if (empty($_SESSION['error_msg'])) { |
152 | | - $_SESSION['ok_msg'] = _('MAIL_ACCOUNT_CREATED_OK',$_POST['v_account'],$_POST[v_domain],$_POST['v_account'],$_POST[v_domain]); |
| 152 | + $_SESSION['ok_msg'] = __('MAIL_ACCOUNT_CREATED_OK',$_POST['v_account'],$_POST[v_domain],$_POST['v_account'],$_POST[v_domain]); |
153 | 153 | unset($v_account); |
154 | 154 | unset($v_password); |
155 | 155 | unset($v_password); |
|
0 commit comments