Simplify domain management by using the same page for both locations where domains can be edited. This removes a large amount of duplicated code, each prone to its own bugs.

Signed-off-by: DL6ER <dl6er@dl6er.de>
This commit is contained in:
DL6ER
2020-02-14 20:21:01 +01:00
parent 843e46d84a
commit 2d975b8bac
9 changed files with 98 additions and 629 deletions

View File

@@ -428,13 +428,13 @@ if($auth) {
</div>
<!-- sidebar menu: : style can be found in sidebar.less -->
<?php
if($scriptname === "list.php")
if($scriptname === "groups-domains.php")
{
if($_GET["l"] === "white")
if($_GET["type"] === "white")
{
$scriptname = "whitelist";
}
elseif($_GET["l"] === "black")
elseif($_GET["type"] === "black")
{
$scriptname = "blacklist";
}
@@ -486,13 +486,13 @@ if($auth) {
</li>
<!-- Whitelist -->
<li<?php if($scriptname === "whitelist"){ ?> class="active"<?php } ?>>
<a href="list.php?l=white">
<a href="groups-domains.php?type=white">
<i class="fa fa-check-circle "></i> <span>Whitelist</span>
</a>
</li>
<!-- Blacklist -->
<li<?php if($scriptname === "blacklist"){ ?> class="active"<?php } ?>>
<a href="list.php?l=black">
<a href="groups-domains.php?type=black">
<i class="fa fa-ban"></i> <span>Blacklist</span>
</a>
</li>