diff --git a/bin/v_search_object b/bin/v_search_object new file mode 100755 index 000000000..fbbf1d331 --- /dev/null +++ b/bin/v_search_object @@ -0,0 +1,145 @@ +#!/bin/bash +# info: search objects +# options: object [format] +# +# The function that allows to find system objects. + + +#----------------------------------------------------------# +# Variable&Function # +#----------------------------------------------------------# + +# Argument defenition +object=$1 +format=${2-shell} + +# Includes +source $VESTA/conf/vesta.conf +source $VESTA/func/main.sh + +#----------------------------------------------------------# +# Verifications # +#----------------------------------------------------------# + +check_args '1' "$#" 'object [format]' +validate_format 'object' + + +#----------------------------------------------------------# +# Action # +#----------------------------------------------------------# + +conf=$(mktemp) +i=0 +OLD_IFS=$IFS +IFS=$'\n' + +# User loop +for user in $(ls $VESTA/data/users/); do + # Search query + search=$(grep "$object" \ + $VESTA/data/users/$user/web.conf \ + $VESTA/data/users/$user/dns.conf \ + $VESTA/data/users/$user/mail.conf \ + $VESTA/data/users/$user/db.conf) + + for row in $search; do + # Initialise variable + key='' + result='' + dom_alias='' + suspended='' + object_time='' + object_date='' + + # Parsing result + type=$(echo $row |cut -f 1 -d : |cut -f 8 -d / |cut -f 1 -d \.) + data=$(echo $row |cut -f 2,3,4,5 -d :) + eval "$data" + + # Check WEB domain + dom_alias='' + if [ "$type" = 'web' ]; then + if [ -n "$(echo $DOMAIN |grep $object)" ]; then + # Check domain alias + check_dom_alias="$(echo $ALIAS| tr ',' '\n' |grep $object)" + if [ ! -z "$check_dom_alias" ];then + dom_alias=$(echo $check_dom_alias | tr ' ' ',') + fi + key="DOMAIN" + result="$DOMAIN" + suspended=$SUSPENDED + object_time=$TIME + object_date=$DATE + ((i ++)) + fi + fi + + # DNS + if [ "$type" = 'dns' ]; then + if [ -n "$(echo $DOMAIN |grep $object)" ]; then + key="DOMAIN" + result="$DOMAIN" + suspended=$SUSPENDED + object_time=$TIME + object_date=$DATE + ((i ++)) + fi + fi + + # MAIL + if [ "$type" = 'mail' ]; then + if [ -n "$(echo $DOMAIN |grep $object)" ]; then + key="DOMAIN" + result="$DOMAIN" + suspended=$SUSPENDED + object_time=$TIME + object_date=$DATE + ((i ++)) + fi + fi + + # DB + if [ "$type" = 'db' ]; then + if [ -n "$(echo $DB |grep $object)" ]; then + key="DATABASE" + result="$DB" + suspended=$SUSPENDED + object_time=$TIME + object_date=$DATE + ((i ++)) + fi + fi + + if [ ! -z "$result" ]; then + str="ID='$i' USER='$user' TYPE='$type' KEY='$key'" + str="$str RESULT='$result' ALIAS='$dom_alias'" + str="$str SUSPENDED='$suspended' TIME='$object_time'" + str="$str DATE='$object_date'" + echo $str >> $conf + fi + done +done +IFS=$OLD_IFS + +# Defining fileds to select +fields='$ID $USER $TYPE $KEY $RESULT $ALIAS $SUSPENDED $TIME $DATE' + +# Listing domains +case $format in + json) json_list ;; + plain) nohead=1; shell_list ;; + shell) fields='$USER $TYPE $KEY $RESULT $ALIAS'; shell_list |column -t;; + *) check_args '2' '0' 'object [format]' +esac + +rm $conf + +#----------------------------------------------------------# +# Vesta # +#----------------------------------------------------------# + +# Logging +#log_event "$OK" "$EVENT" + +exit diff --git a/web/delete/backup/index.php b/web/delete/backup/index.php index 37b833c11..f701276a8 100644 --- a/web/delete/backup/index.php +++ b/web/delete/backup/index.php @@ -5,7 +5,11 @@ ob_start(); session_start(); include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); -//if ($_SESSION['user'] == 'admin') { + // Delete as someone else? + if (($_SESSION['user'] == 'admin') && (!empty($_GET['user']))) { + $user=$_GET['user']; + } + if (!empty($_GET['backup'])) { $v_username = escapeshellarg($user); $v_backup = escapeshellarg($_GET['backup']); @@ -20,4 +24,10 @@ include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); //} +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/backup/"); +exit; diff --git a/web/delete/cron/index.php b/web/delete/cron/index.php index 6e6a2e8af..f8cfe5365 100644 --- a/web/delete/cron/index.php +++ b/web/delete/cron/index.php @@ -5,7 +5,11 @@ ob_start(); session_start(); include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); -//if ($_SESSION['user'] == 'admin') { + // Delete as someone else? + if (($_SESSION['user'] == 'admin') && (!empty($_GET['user']))) { + $user=$_GET['user']; + } + if (!empty($_GET['job'])) { $v_username = escapeshellarg($user); $v_job = escapeshellarg($_GET['job']); @@ -20,4 +24,10 @@ include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); //} +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/cron/"); +exit; diff --git a/web/delete/db/index.php b/web/delete/db/index.php index c1ebc5315..3d0ad8385 100644 --- a/web/delete/db/index.php +++ b/web/delete/db/index.php @@ -5,7 +5,11 @@ ob_start(); session_start(); include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); -//if ($_SESSION['user'] == 'admin') { + // Delete as someone else? + if (($_SESSION['user'] == 'admin') && (!empty($_GET['user']))) { + $user=$_GET['user']; + } + if (!empty($_GET['database'])) { $v_username = escapeshellarg($user); $v_database = escapeshellarg($_GET['database']); @@ -20,4 +24,10 @@ include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); //} +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/db/"); +exit; diff --git a/web/delete/dns/index.php b/web/delete/dns/index.php index 7b1449fc0..1d4e35af3 100644 --- a/web/delete/dns/index.php +++ b/web/delete/dns/index.php @@ -5,7 +5,11 @@ ob_start(); session_start(); include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); -//if ($_SESSION['user'] == 'admin') { + // Delete as someone else? + if (($_SESSION['user'] == 'admin') && (!empty($_GET['user']))) { + $user=$_GET['user']; + } + // DNS domain if ((!empty($_GET['domain'])) && (empty($_GET['record_id']))) { $v_username = escapeshellarg($user); @@ -17,6 +21,11 @@ include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); $_SESSION['error_msg'] = $error; } unset($output); + $back=getenv("HTTP_REFERER"); + if (!empty($back)) { + header("Location: ".$back); + exit; + } header("Location: /list/dns/"); exit; } @@ -33,11 +42,20 @@ include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); $_SESSION['error_msg'] = $error; } unset($output); - - unset($output); + $back=getenv("HTTP_REFERER"); + if (!empty($back)) { + header("Location: ".$back); + exit; + } header("Location: /list/dns/?domain=".$_GET['domain']); exit; } //} +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/dns/"); +exit; diff --git a/web/delete/ip/index.php b/web/delete/ip/index.php index 46ab470e8..e088e6592 100644 --- a/web/delete/ip/index.php +++ b/web/delete/ip/index.php @@ -19,4 +19,10 @@ if ($_SESSION['user'] == 'admin') { } +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/ip/"); +exit; diff --git a/web/delete/mail/index.php b/web/delete/mail/index.php index 6ccd8120a..ff429c858 100644 --- a/web/delete/mail/index.php +++ b/web/delete/mail/index.php @@ -5,7 +5,11 @@ ob_start(); session_start(); include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); -//if ($_SESSION['user'] == 'admin') { + // Delete as someone else? + if (($_SESSION['user'] == 'admin') && (!empty($_GET['user']))) { + $user=$_GET['user']; + } + // Mail domain if ((!empty($_GET['domain'])) && (empty($_GET['account']))) { $v_username = escapeshellarg($user); @@ -17,6 +21,11 @@ include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); $_SESSION['error_msg'] = $error; } unset($output); + $back=getenv("HTTP_REFERER"); + if (!empty($back)) { + header("Location: ".$back); + exit; + } header("Location: /list/mail/"); exit; } @@ -33,9 +42,20 @@ include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); $_SESSION['error_msg'] = $error; } unset($output); + $back=getenv("HTTP_REFERER"); + if (!empty($back)) { + header("Location: ".$back); + exit; + } header("Location: /list/mail/?domain=".$_GET['domain']); exit; } //} +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/mail/"); +exit; diff --git a/web/delete/package/index.php b/web/delete/package/index.php index 28d2d1ee2..57d27a692 100644 --- a/web/delete/package/index.php +++ b/web/delete/package/index.php @@ -18,4 +18,10 @@ if ($_SESSION['user'] == 'admin') { unset($output); } +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/package/"); +exit; diff --git a/web/delete/user/index.php b/web/delete/user/index.php index 13a5ae242..338b5f548 100644 --- a/web/delete/user/index.php +++ b/web/delete/user/index.php @@ -18,4 +18,10 @@ if ($_SESSION['user'] == 'admin') { unset($output); } +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/user/"); +exit; diff --git a/web/delete/web/index.php b/web/delete/web/index.php index 330671621..574258259 100644 --- a/web/delete/web/index.php +++ b/web/delete/web/index.php @@ -5,6 +5,11 @@ ob_start(); session_start(); include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); + // Delete as someone else? + if (($_SESSION['user'] == 'admin') && (!empty($_GET['user']))) { + $user=$_GET['user']; + } + if (!empty($_GET['domain'])) { $v_username = escapeshellarg($user); $v_domain = escapeshellarg($_GET['domain']); @@ -45,4 +50,10 @@ if (!empty($_GET['domain'])) { } } +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/web/"); +exit; diff --git a/web/edit/db/index.php b/web/edit/db/index.php index d11b8cc51..a0691958a 100644 --- a/web/edit/db/index.php +++ b/web/edit/db/index.php @@ -13,15 +13,17 @@ include($_SERVER['DOCUMENT_ROOT'].'/templates/header.html'); // Panel top_panel($user,$TAB); -// Are you admin? -//if ($_SESSION['user'] == 'admin') { - // Check user argument? if (empty($_GET['database'])) { header("Location: /list/db/"); exit; } + // Edit as someone else? + if (($_SESSION['user'] == 'admin') && (!empty($_GET['user']))) { + $user=escapeshellarg($_GET['user']); + } + $v_database = escapeshellarg($_GET['database']); exec (VESTA_CMD."v_list_database ".$user." ".$v_database." 'json'", $output, $return_var); if ($return_var != 0) { diff --git a/web/edit/dns/index.php b/web/edit/dns/index.php index 574567cda..d2e8446fa 100644 --- a/web/edit/dns/index.php +++ b/web/edit/dns/index.php @@ -13,15 +13,17 @@ include($_SERVER['DOCUMENT_ROOT'].'/templates/header.html'); // Panel top_panel($user,$TAB); -// Are you admin? -//if ($_SESSION['user'] == 'admin') { - // Check user argument? if (empty($_GET['domain'])) { header("Location: /list/dns/"); exit; } + // Edit as someone else? + if (($_SESSION['user'] == 'admin') && (!empty($_GET['user']))) { + $user=escapeshellarg($_GET['user']); + } + // Check domain if ((!empty($_GET['domain'])) && (empty($_GET['record_id']))) { $v_domain = escapeshellarg($_GET['domain']); diff --git a/web/edit/mail/index.php b/web/edit/mail/index.php index c6ccdf9ed..c0cdbedc6 100644 --- a/web/edit/mail/index.php +++ b/web/edit/mail/index.php @@ -13,15 +13,17 @@ include($_SERVER['DOCUMENT_ROOT'].'/templates/header.html'); // Panel top_panel($user,$TAB); -// Are you admin? -//if ($_SESSION['user'] == 'admin') { - // Check user argument? if (empty($_GET['domain'])) { header("Location: /list/mail/"); exit; } + // Edit as someone else? + if (($_SESSION['user'] == 'admin') && (!empty($_GET['user']))) { + $user=escapeshellarg($_GET['user']); + } + // Check domain if ((!empty($_GET['domain'])) && (empty($_GET['account']))) { $v_domain = escapeshellarg($_GET['domain']); diff --git a/web/edit/web/index.php b/web/edit/web/index.php index d92665717..18c9791df 100644 --- a/web/edit/web/index.php +++ b/web/edit/web/index.php @@ -14,8 +14,6 @@ include($_SERVER['DOCUMENT_ROOT'].'/templates/header.html'); // Panel top_panel($user,$TAB); -// Are you admin? -//if ($_SESSION['user'] == 'admin') { // Check user argument? if (empty($_GET['domain'])) { @@ -23,6 +21,12 @@ top_panel($user,$TAB); exit; } + // Edit as someone else? + if (($_SESSION['user'] == 'admin') && (!empty($_GET['user']))) { + $user=escapeshellarg($_GET['user']); + } + + // Check domain $v_domain = escapeshellarg($_GET['domain']); exec (VESTA_CMD."v_list_web_domain ".$user." ".$v_domain." json", $output, $return_var); diff --git a/web/search/index.php b/web/search/index.php index c383217ff..5cfa01bcf 100644 --- a/web/search/index.php +++ b/web/search/index.php @@ -1,16 +1,39 @@ - diff --git a/web/templates/admin/add_db.html b/web/templates/admin/add_db.html index 9a9528c08..2264b2d8c 100644 --- a/web/templates/admin/add_db.html +++ b/web/templates/admin/add_db.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/add_dns.html b/web/templates/admin/add_dns.html index 703929a0b..2ebb32464 100644 --- a/web/templates/admin/add_dns.html +++ b/web/templates/admin/add_dns.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/add_dns_rec.html b/web/templates/admin/add_dns_rec.html index 527e5ea82..012ee32d5 100644 --- a/web/templates/admin/add_dns_rec.html +++ b/web/templates/admin/add_dns_rec.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/add_ip.html b/web/templates/admin/add_ip.html index 182f86161..ea6ef1da6 100644 --- a/web/templates/admin/add_ip.html +++ b/web/templates/admin/add_ip.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/add_mail.html b/web/templates/admin/add_mail.html index 6c28f7408..77aafe2c0 100644 --- a/web/templates/admin/add_mail.html +++ b/web/templates/admin/add_mail.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/add_mail_acc.html b/web/templates/admin/add_mail_acc.html index e4be225c3..05b022a38 100644 --- a/web/templates/admin/add_mail_acc.html +++ b/web/templates/admin/add_mail_acc.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/add_package.html b/web/templates/admin/add_package.html index b09c524aa..9a78f109c 100644 --- a/web/templates/admin/add_package.html +++ b/web/templates/admin/add_package.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/add_user.html b/web/templates/admin/add_user.html index 52132280d..090fd6cf5 100644 --- a/web/templates/admin/add_user.html +++ b/web/templates/admin/add_user.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/add_web.html b/web/templates/admin/add_web.html index 7ec0a9814..7654098dc 100644 --- a/web/templates/admin/add_web.html +++ b/web/templates/admin/add_web.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/edit_cron.html b/web/templates/admin/edit_cron.html index 32e2f0aa9..aefdbb335 100644 --- a/web/templates/admin/edit_cron.html +++ b/web/templates/admin/edit_cron.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/edit_db.html b/web/templates/admin/edit_db.html index 15eae4e8e..d790a955e 100644 --- a/web/templates/admin/edit_db.html +++ b/web/templates/admin/edit_db.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/edit_dns.html b/web/templates/admin/edit_dns.html index 365887cb6..952a496e8 100644 --- a/web/templates/admin/edit_dns.html +++ b/web/templates/admin/edit_dns.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/edit_dns_rec.html b/web/templates/admin/edit_dns_rec.html index d0dc68da6..2f22346a3 100644 --- a/web/templates/admin/edit_dns_rec.html +++ b/web/templates/admin/edit_dns_rec.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/edit_ip.html b/web/templates/admin/edit_ip.html index f37e9b11a..49a5fdfa4 100644 --- a/web/templates/admin/edit_ip.html +++ b/web/templates/admin/edit_ip.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/edit_mail.html b/web/templates/admin/edit_mail.html index 20d460e84..b971d78eb 100644 --- a/web/templates/admin/edit_mail.html +++ b/web/templates/admin/edit_mail.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/edit_mail_acc.html b/web/templates/admin/edit_mail_acc.html index 0047e2520..8e7885634 100644 --- a/web/templates/admin/edit_mail_acc.html +++ b/web/templates/admin/edit_mail_acc.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/edit_package.html b/web/templates/admin/edit_package.html index 7ea1a8828..dc34d9f04 100644 --- a/web/templates/admin/edit_package.html +++ b/web/templates/admin/edit_package.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/edit_user.html b/web/templates/admin/edit_user.html index ba0731d34..fc1969c55 100644 --- a/web/templates/admin/edit_user.html +++ b/web/templates/admin/edit_user.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/admin/edit_web.html b/web/templates/admin/edit_web.html index 99434ee1b..200cfd3d2 100644 --- a/web/templates/admin/edit_web.html +++ b/web/templates/admin/edit_web.html @@ -1,7 +1,15 @@ + - - + diff --git a/web/templates/admin/list_backup.html b/web/templates/admin/list_backup.html index f7c50ed5a..164000a0f 100644 --- a/web/templates/admin/list_backup.html +++ b/web/templates/admin/list_backup.html @@ -8,7 +8,7 @@
- +
diff --git a/web/templates/admin/list_cron.html b/web/templates/admin/list_cron.html index a7379960b..b0810f43d 100644 --- a/web/templates/admin/list_cron.html +++ b/web/templates/admin/list_cron.html @@ -7,7 +7,7 @@
- +
diff --git a/web/templates/admin/list_db.html b/web/templates/admin/list_db.html index 52f141e3e..436718678 100644 --- a/web/templates/admin/list_db.html +++ b/web/templates/admin/list_db.html @@ -8,7 +8,7 @@
- +
diff --git a/web/templates/admin/list_dns.html b/web/templates/admin/list_dns.html index f9db4e851..14f3acc93 100644 --- a/web/templates/admin/list_dns.html +++ b/web/templates/admin/list_dns.html @@ -7,7 +7,7 @@
- +
diff --git a/web/templates/admin/list_dns_rec.html b/web/templates/admin/list_dns_rec.html index 958480388..fd3f89512 100644 --- a/web/templates/admin/list_dns_rec.html +++ b/web/templates/admin/list_dns_rec.html @@ -8,7 +8,7 @@
- +
diff --git a/web/templates/admin/list_ip.html b/web/templates/admin/list_ip.html index 8cdb05a55..14e1f7e80 100644 --- a/web/templates/admin/list_ip.html +++ b/web/templates/admin/list_ip.html @@ -8,7 +8,7 @@
- +
diff --git a/web/templates/admin/list_log.html b/web/templates/admin/list_log.html index 810865ac4..028430412 100644 --- a/web/templates/admin/list_log.html +++ b/web/templates/admin/list_log.html @@ -7,7 +7,7 @@
- +
@@ -28,7 +28,7 @@ - +
">
">
">
diff --git a/web/templates/admin/list_mail.html b/web/templates/admin/list_mail.html index 23b13fbf9..05a63b990 100644 --- a/web/templates/admin/list_mail.html +++ b/web/templates/admin/list_mail.html @@ -7,7 +7,7 @@
- +
diff --git a/web/templates/admin/list_mail_acc.html b/web/templates/admin/list_mail_acc.html index 188bc869e..544d33e60 100644 --- a/web/templates/admin/list_mail_acc.html +++ b/web/templates/admin/list_mail_acc.html @@ -8,7 +8,7 @@
- +
diff --git a/web/templates/admin/list_packages.html b/web/templates/admin/list_packages.html index 417bb0aa3..f6c17b09c 100644 --- a/web/templates/admin/list_packages.html +++ b/web/templates/admin/list_packages.html @@ -8,7 +8,7 @@
- +
diff --git a/web/templates/admin/list_rrd.html b/web/templates/admin/list_rrd.html index f12d93aa8..4d100769f 100644 --- a/web/templates/admin/list_rrd.html +++ b/web/templates/admin/list_rrd.html @@ -11,7 +11,7 @@
- +
@@ -33,11 +33,10 @@ ?> - - - - - + + +
">
active
+ + +
">
">
diff --git a/web/templates/admin/list_search.html b/web/templates/admin/list_search.html new file mode 100644 index 000000000..5be2a593f --- /dev/null +++ b/web/templates/admin/list_search.html @@ -0,0 +1,137 @@ + + + + + + +
+ +
+ + $value) { + ++$i; + if ($data[$key]['SUSPENDED'] == 'yes') { + $status = 'suspended'; + $spnd_action = 'unsuspend' ; + } else { + $status = 'active'; + $spnd_action = 'suspend'; + } + if ($data[$key]['TYPE'] == 'db') { + $object = 'database'; + } else { + $object = strtolower($data[$key]['TYPE']." ".$data[$key]['KEY']); + } + ?> + + + + + + + +
+ + + +
">
">
+
+ + + + + + + + +
login as edit + + + + + + + delete + + +
+ + + + + + + + +
+ + + + + +
+ Object: + + +
+
+ + + + + +
+ Owner: + + +
+
+ + + + + +
+ Status: + + +
+
+
+ + + + + + + +
+ +
+
+ diff --git a/web/templates/admin/list_stats.html b/web/templates/admin/list_stats.html index 2692e1a0e..de7e69af7 100644 --- a/web/templates/admin/list_stats.html +++ b/web/templates/admin/list_stats.html @@ -7,7 +7,7 @@
- +
@@ -26,11 +26,9 @@ ?> - - - - - +
">
active
+ +
">
diff --git a/web/templates/admin/list_user.html b/web/templates/admin/list_user.html index f3921edde..82adaaa6c 100644 --- a/web/templates/admin/list_user.html +++ b/web/templates/admin/list_user.html @@ -14,7 +14,7 @@
- +
diff --git a/web/templates/admin/list_web.html b/web/templates/admin/list_web.html index 9df2c5cb1..d26bd7704 100644 --- a/web/templates/admin/list_web.html +++ b/web/templates/admin/list_web.html @@ -8,7 +8,7 @@
- +
diff --git a/web/templates/header.html b/web/templates/header.html index 0f2ae172d..fed86e68d 100644 --- a/web/templates/header.html +++ b/web/templates/header.html @@ -408,7 +408,7 @@ .cron { color: #555555; font-family: Arial, sans-serif; - font-size: 14pt; + font-size: 18px; } .log { @@ -433,7 +433,7 @@ .fullname { font-family: Arial; - font-size: 14pt; + font-size: 18px; color: #99a7af; padding: 0 0 0 8px; } @@ -480,7 +480,7 @@ color: #484243; } - .add-name { + .name { font-family: Arial; font-size: 16pt; color: #777; @@ -489,14 +489,14 @@ .add-ok { font-family: Arial; - font-size: 14pt; + font-size: 18px; color: #62a358; padding: 0 0 0 6px; } .add-error { font-family: Arial; - font-size: 14pt; + font-size: 18px; color: #de6c5d; padding: 0 0 0 6px; } @@ -512,7 +512,7 @@ border-radius: 3px 3px 3px 3px; color: #555555; font-family: Arial,sans-serif; - font-size: 14pt; + font-size: 18px; padding: 6px; width: 360px; height: 120px; @@ -532,9 +532,10 @@ border-radius: 3px 3px 3px 3px; color: #555555; font-family: Arial,sans-serif; - font-size: 14pt; + font-size: 18px; padding: 6px; width: 360px; + line-height:22px; } .add-input:hover { diff --git a/web/templates/user/add_dns.html b/web/templates/user/add_dns.html index 1f3209fa4..528937bbe 100644 --- a/web/templates/user/add_dns.html +++ b/web/templates/user/add_dns.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/user/add_web.html b/web/templates/user/add_web.html index 921eef0b6..036d92dfb 100644 --- a/web/templates/user/add_web.html +++ b/web/templates/user/add_web.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/user/edit_dns.html b/web/templates/user/edit_dns.html index 8633b203f..eaed11403 100644 --- a/web/templates/user/edit_dns.html +++ b/web/templates/user/edit_dns.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/user/edit_user.html b/web/templates/user/edit_user.html index 08a806db6..0f324a168 100644 --- a/web/templates/user/edit_user.html +++ b/web/templates/user/edit_user.html @@ -1,7 +1,15 @@ + - diff --git a/web/templates/user/edit_web.html b/web/templates/user/edit_web.html index e110a408f..a8683e545 100644 --- a/web/templates/user/edit_web.html +++ b/web/templates/user/edit_web.html @@ -1,7 +1,15 @@ + -
- +
diff --git a/web/templates/user/list_cron.html b/web/templates/user/list_cron.html index 258fa2881..44573f364 100644 --- a/web/templates/user/list_cron.html +++ b/web/templates/user/list_cron.html @@ -7,7 +7,7 @@
- +
diff --git a/web/templates/user/list_db.html b/web/templates/user/list_db.html index 35e8d8622..f2daddc44 100644 --- a/web/templates/user/list_db.html +++ b/web/templates/user/list_db.html @@ -8,7 +8,7 @@
- +
diff --git a/web/templates/user/list_dns.html b/web/templates/user/list_dns.html index cbb37976c..fbf4aa2dc 100644 --- a/web/templates/user/list_dns.html +++ b/web/templates/user/list_dns.html @@ -7,7 +7,7 @@
- +
diff --git a/web/templates/user/list_dns_rec.html b/web/templates/user/list_dns_rec.html index 80451f052..9211d35a6 100644 --- a/web/templates/user/list_dns_rec.html +++ b/web/templates/user/list_dns_rec.html @@ -8,7 +8,7 @@
- +
diff --git a/web/templates/user/list_mail.html b/web/templates/user/list_mail.html index 480f63e96..d6271418b 100644 --- a/web/templates/user/list_mail.html +++ b/web/templates/user/list_mail.html @@ -7,7 +7,7 @@
- +
diff --git a/web/templates/user/list_mail_acc.html b/web/templates/user/list_mail_acc.html index d8f53d504..61b369f7a 100644 --- a/web/templates/user/list_mail_acc.html +++ b/web/templates/user/list_mail_acc.html @@ -8,7 +8,7 @@
- +
diff --git a/web/templates/user/list_user.html b/web/templates/user/list_user.html index 600d440c7..c6cf709fc 100644 --- a/web/templates/user/list_user.html +++ b/web/templates/user/list_user.html @@ -14,7 +14,7 @@
- +
diff --git a/web/templates/user/list_web.html b/web/templates/user/list_web.html index 146ac4373..93249ed9d 100644 --- a/web/templates/user/list_web.html +++ b/web/templates/user/list_web.html @@ -8,7 +8,7 @@
- +
diff --git a/web/unsuspend/cron/index.php b/web/unsuspend/cron/index.php index ccbe2f2df..4a6ea8b9b 100644 --- a/web/unsuspend/cron/index.php +++ b/web/unsuspend/cron/index.php @@ -6,6 +6,9 @@ session_start(); include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); if ($_SESSION['user'] == 'admin') { + if (!empty($_GET['user'])) { + $user=$_GET['user']; + } if (!empty($_GET['job'])) { $v_username = escapeshellarg($user); $v_job = escapeshellarg($_GET['job']); @@ -20,4 +23,10 @@ if ($_SESSION['user'] == 'admin') { } +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/cron/"); +exit; diff --git a/web/unsuspend/db/index.php b/web/unsuspend/db/index.php index 738dd2308..49ba84bee 100644 --- a/web/unsuspend/db/index.php +++ b/web/unsuspend/db/index.php @@ -6,6 +6,9 @@ session_start(); include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); if ($_SESSION['user'] == 'admin') { + if (!empty($_GET['user'])) { + $user=$_GET['user']; + } if (!empty($_GET['database'])) { $v_username = escapeshellarg($user); $v_database = escapeshellarg($_GET['database']); @@ -14,4 +17,10 @@ if ($_SESSION['user'] == 'admin') { } } +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/db/"); +exit; diff --git a/web/unsuspend/dns/index.php b/web/unsuspend/dns/index.php index c564227a2..6311503e5 100644 --- a/web/unsuspend/dns/index.php +++ b/web/unsuspend/dns/index.php @@ -6,6 +6,9 @@ session_start(); include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); if ($_SESSION['user'] == 'admin') { + if (!empty($_GET['user'])) { + $user=$_GET['user']; + } // DNS domain if ((!empty($_GET['domain'])) && (empty($_GET['record_id']))) { $v_username = escapeshellarg($user); @@ -17,6 +20,11 @@ if ($_SESSION['user'] == 'admin') { $_SESSION['error_msg'] = $error; } unset($output); + $back=getenv("HTTP_REFERER"); + if (!empty($back)) { + header("Location: ".$back); + exit; + } header("Location: /list/dns/"); exit; @@ -34,10 +42,21 @@ if ($_SESSION['user'] == 'admin') { $_SESSION['error_msg'] = $error; } unset($output); + $back=getenv("HTTP_REFERER"); + if (!empty($back)) { + header("Location: ".$back); + exit; + } header("Location: /list/dns/?domain=".$_GET['domain']); exit; } } +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/dns/"); +exit; diff --git a/web/unsuspend/mail/index.php b/web/unsuspend/mail/index.php index ac5303dfa..a6d50d46f 100644 --- a/web/unsuspend/mail/index.php +++ b/web/unsuspend/mail/index.php @@ -6,6 +6,9 @@ session_start(); include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); if ($_SESSION['user'] == 'admin') { + if (!empty($_GET['user'])) { + $user=$_GET['user']; + } // Mail domain if ((!empty($_GET['domain'])) && (empty($_GET['account']))) { $v_username = escapeshellarg($user); @@ -17,6 +20,11 @@ if ($_SESSION['user'] == 'admin') { $_SESSION['error_msg'] = $error; } unset($output); + $back=getenv("HTTP_REFERER"); + if (!empty($back)) { + header("Location: ".$back); + exit; + } header("Location: /list/mail/"); exit; } @@ -33,9 +41,20 @@ if ($_SESSION['user'] == 'admin') { $_SESSION['error_msg'] = $error; } unset($output); + $back=getenv("HTTP_REFERER"); + if (!empty($back)) { + header("Location: ".$back); + exit; + } header("Location: /list/mail/?domain=".$_GET['domain']); exit; } } +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/mail/"); +exit; diff --git a/web/unsuspend/user/index.php b/web/unsuspend/user/index.php index 6c6b8e49a..2ff2a752d 100644 --- a/web/unsuspend/user/index.php +++ b/web/unsuspend/user/index.php @@ -19,4 +19,10 @@ if ($_SESSION['user'] == 'admin') { unset($output); } +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/user/"); +exit; diff --git a/web/unsuspend/web/index.php b/web/unsuspend/web/index.php index 10e2f2116..e107c1fa8 100644 --- a/web/unsuspend/web/index.php +++ b/web/unsuspend/web/index.php @@ -6,6 +6,9 @@ session_start(); include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); if ($_SESSION['user'] == 'admin') { + if (!empty($_GET['user'])) { + $user=$_GET['user']; + } if (!empty($_GET['domain'])) { $v_username = escapeshellarg($user); $v_domain = escapeshellarg($_GET['domain']); @@ -19,4 +22,10 @@ if ($_SESSION['user'] == 'admin') { unset($output); } +$back=getenv("HTTP_REFERER"); +if (!empty($back)) { + header("Location: ".$back); + exit; +} header("Location: /list/web/"); +exit;