mirror of
https://github.com/serghey-rodin/vesta.git
synced 2025-08-14 10:37:39 -07:00
i18n integration
This commit is contained in:
parent
a8a86aced9
commit
fb216fc3ee
18 changed files with 288 additions and 225 deletions
|
@ -34,7 +34,7 @@ if ($_SESSION['user'] == 'admin') {
|
|||
$v_email = escapeshellarg($_POST['v_email']);
|
||||
$v_fname = escapeshellarg($_POST['v_fname']);
|
||||
$v_lname = escapeshellarg($_POST['v_lname']);
|
||||
if (empty($_POST['v_notify'])) $v_notify = 'off';
|
||||
$v_notify = $_POST['v_notify'];
|
||||
|
||||
// Validate email
|
||||
if (!filter_var($_POST['v_email'], FILTER_VALIDATE_EMAIL)) {
|
||||
|
@ -60,8 +60,8 @@ if ($_SESSION['user'] == 'admin') {
|
|||
if (empty($error)) $error = _('Error: vesta did not return any output.');
|
||||
$_SESSION['error_msg'] = $error;
|
||||
} else {
|
||||
if (empty($v_notify)) {
|
||||
$to = $_POST['v_email'];
|
||||
if (!empty($v_notify)) {
|
||||
$to = $_POST['v_notify'];
|
||||
$subject = _("Welcome to Vesta Control Panel");
|
||||
$hostname = exec('hostname');
|
||||
$from = _('MAIL_FROM',$hostname);
|
||||
|
@ -80,6 +80,7 @@ if ($_SESSION['user'] == 'admin') {
|
|||
unset($v_email);
|
||||
unset($v_fname);
|
||||
unset($v_lname);
|
||||
unset($v_notify);
|
||||
}
|
||||
unset($output);
|
||||
}
|
||||
|
|
|
@ -11,7 +11,7 @@ include($_SERVER['DOCUMENT_ROOT'].'/templates/header.html');
|
|||
|
||||
// Panel
|
||||
top_panel($user,$TAB);
|
||||
|
||||
$v_ftp_email = $panel[$user]['CONTACT'];
|
||||
if (!empty($_POST['ok'])) {
|
||||
// Check input
|
||||
if (empty($_POST['v_domain'])) $errors[] = _('domain');
|
||||
|
@ -91,7 +91,7 @@ top_panel($user,$TAB);
|
|||
$_SESSION['error_msg'] = $error;
|
||||
}
|
||||
unset($output);
|
||||
|
||||
|
||||
// Add DNS
|
||||
if (($_POST['v_dns'] == 'on') && (empty($_SESSION['error_msg']))) {
|
||||
exec (VESTA_CMD."v-add-dns-domain ".$user." ".$v_domain." ".$v_ip, $output, $return_var);
|
||||
|
@ -256,7 +256,7 @@ top_panel($user,$TAB);
|
|||
$from = _('MAIL_FROM',$hostname);
|
||||
$mailtext .= _('FTP_ACCOUNT_READY',$_POST['v_domain'],$user,$_POST['v_ftp_user'],$_POST['v_ftp_password']);
|
||||
send_email($to, $subject, $mailtext, $from);
|
||||
unset($v_ftp_email);
|
||||
//unset($v_ftp_email);
|
||||
}
|
||||
}
|
||||
unset($v_ftp);
|
||||
|
@ -283,7 +283,7 @@ top_panel($user,$TAB);
|
|||
$_SESSION['error_msg'] = $error;
|
||||
}
|
||||
unset($output);
|
||||
$_SESSION['ok_msg'] = _('HOSTING_DOMAIN_CREATED_OK',$_POST[v_domain],$_POST[v_domain]);
|
||||
$_SESSION['ok_msg'] = _('WEB_DOMAIN_CREATED_OK',$_POST[v_domain],$_POST[v_domain]);
|
||||
unset($v_domain);
|
||||
unset($v_aliases);
|
||||
unset($v_ssl);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue