diff --git a/bin/v_search_object b/bin/v_search_object new file mode 100755 index 00000000..fbbf1d33 --- /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 37b833c1..f701276a 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 6e6a2e8a..f8cfe536 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 c1ebc531..3d0ad838 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 7b1449fc..1d4e35af 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 46ab470e..e088e659 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 6ccd8120..ff429c85 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 28d2d1ee..57d27a69 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 13a5ae24..338b5f54 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 33067162..57425825 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 d11b8cc5..a0691958 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 574567cd..d2e8446f 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 c6ccdf9e..c0cdbedc 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 d9266571..18c9791d 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 c383217f..5cfa01bc 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 9a9528c0..2264b2d8 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 703929a0..2ebb3246 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 527e5ea8..012ee32d 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 182f8616..ea6ef1da 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 6c28f740..77aafe2c 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 e4be225c..05b022a3 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 b09c524a..9a78f109 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 52132280..090fd6cf 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 7ec0a981..7654098d 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 32e2f0aa..aefdbb33 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 15eae4e8..d790a955 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 365887cb..952a496e 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 d0dc68da..2f22346a 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 f37e9b11..49a5fdfa 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 20d460e8..b971d78e 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 0047e252..8e788563 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 7ea1a882..dc34d9f0 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 ba0731d3..fc1969c5 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 99434ee1..200cfd3d 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 f7c50ed5..164000a0 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 a7379960..b0810f43 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 52f141e3..43671867 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 f9db4e85..14f3acc9 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 95848038..fd3f8951 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 8cdb05a5..14e1f7e8 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 810865ac..02843041 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 23b13fbf..05a63b99 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 188bc869..544d33e6 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 417bb0aa..f6c17b09 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 f12d93aa..4d100769 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 00000000..5be2a593 --- /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 2692e1a0..de7e69af 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 f3921edd..82adaaa6 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 9df2c5cb..d26bd770 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 0f2ae172..fed86e68 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 1f3209fa..528937bb 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 921eef0b..036d92df 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 8633b203..eaed1140 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 08a806db..0f324a16 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 e110a408..a8683e54 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 258fa288..44573f36 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 35e8d862..f2daddc4 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 cbb37976..fbf4aa2d 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 80451f05..9211d35a 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 480f63e9..d6271418 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 d8f53d50..61b369f7 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 600d440c..c6cf709f 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 146ac437..93249ed9 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 ccbe2f2d..4a6ea8b9 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 738dd230..49ba84be 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 c564227a..6311503e 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 ac5303df..a6d50d46 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 6c6b8e49..2ff2a752 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 10e2f211..e107c1fa 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;