mirror of
https://github.com/myvesta/vesta
synced 2025-08-14 18:49:21 -07:00
record order change functionality
This commit is contained in:
parent
11eef69dda
commit
57c9816135
9 changed files with 107 additions and 0 deletions
|
@ -195,9 +195,27 @@ if ((!empty($_GET['domain'])) && (empty($_GET['record_id']))) {
|
|||
$restart_dns = 'yes';
|
||||
unset($output);
|
||||
}
|
||||
|
||||
if (($_GET['record_id'] != $_POST['v_record_id']) && (empty($_SESSION['error_msg']))) {
|
||||
$v_old_record_id = escapeshellarg($_GET['record_id']);
|
||||
exec (VESTA_CMD."v-change-dns-domain-record-id ".$v_username." ".$v_domain." ".$v_old_record_id." ".$v_record_id, $output, $return_var);
|
||||
if ($return_var != 0) {
|
||||
$error = implode('<br>', $output);
|
||||
if (empty($error)) $error = __('Error code:',$return_var);
|
||||
$_SESSION['error_msg'] = $error;
|
||||
}
|
||||
unset($output);
|
||||
}
|
||||
|
||||
|
||||
if (empty($_SESSION['error_msg'])) {
|
||||
$_SESSION['ok_msg'] = __('Changes has been saved.');
|
||||
}
|
||||
|
||||
if ($_GET['record_id'] != $_POST['v_record_id']) {
|
||||
header("Location: /edit/dns/?domain=".$_GET['domain']."&record_id=".$_POST['v_record_id']);
|
||||
exit;
|
||||
}
|
||||
}
|
||||
|
||||
include($_SERVER['DOCUMENT_ROOT'].'/templates/admin/edit_dns_rec.html');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue