From 20fbf497852f18c71c3631cec8704726efa9f1a6 Mon Sep 17 00:00:00 2001 From: Alex Date: Thu, 2 Mar 2017 07:52:57 +0200 Subject: [PATCH 1/2] *Fix Proxy setting becomes unset by user* --- web/edit/web/index.php | 4 ++-- web/templates/user/edit_web.html | 23 +++++++++++++++++++++++ 2 files changed, 25 insertions(+), 2 deletions(-) diff --git a/web/edit/web/index.php b/web/edit/web/index.php index 11cda0ea..e736908d 100644 --- a/web/edit/web/index.php +++ b/web/edit/web/index.php @@ -230,8 +230,8 @@ if (!empty($_POST['save'])) { $restart_proxy = 'yes'; } - // Change proxy template / Update extension list - if ((!empty($_SESSION['PROXY_SYSTEM'])) && (!empty($v_proxy)) && (!empty($_POST['v_proxy'])) && (empty($_SESSION['error_msg']))) { + // Change proxy template / Update extension list (admin only) + if ((!empty($_SESSION['PROXY_SYSTEM'])) && (!empty($v_proxy)) && (!empty($_POST['v_proxy'])) && (empty($_SESSION['error_msg'])) && ($_SESSION['user'] == 'admin')) { $ext = preg_replace("/\n/", " ", $_POST['v_proxy_ext']); $ext = preg_replace("/,/", " ", $ext); $ext = preg_replace('/\s+/', ' ',$ext); diff --git a/web/templates/user/edit_web.html b/web/templates/user/edit_web.html index 20358b03..a7f54db0 100644 --- a/web/templates/user/edit_web.html +++ b/web/templates/user/edit_web.html @@ -85,6 +85,29 @@ + + + + + + + + + + + + + + + +
+ +
+ +
+ + + From 1bc576c4c6ed072dba923ab436ac0062a39fee6a Mon Sep 17 00:00:00 2001 From: Alex Date: Thu, 2 Mar 2017 12:02:45 +0200 Subject: [PATCH 2/2] Delete empty echo ""; --- web/templates/user/edit_web.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web/templates/user/edit_web.html b/web/templates/user/edit_web.html index a7f54db0..f26559b5 100644 --- a/web/templates/user/edit_web.html +++ b/web/templates/user/edit_web.html @@ -85,7 +85,7 @@ - + @@ -107,7 +107,7 @@ - +