Put wildcard blocking entries into their own table

This commit is contained in:
DL6ER
2016-12-31 16:06:21 +00:00
parent 754fa117ec
commit 05f2df720e
2 changed files with 11 additions and 1 deletions
+5
View File
@@ -49,7 +49,12 @@ function getFullName() {
</div>
<!-- Domain List -->
<h3>Exactl blocking</h3>
<ul class="list-group" id="list"></ul>
<?php if($list === "black") { ?>
<h3>Wildcard blocking</h3>
<ul class="list-group" id="list-wildcard"></ul>
<?php } ?>
<?php
require "scripts/pi-hole/php/footer.php";
+6 -1
View File
@@ -26,7 +26,12 @@ function sub(index, entry) {
}
function refresh(fade) {
var listw;
var list = $("#list");
if(listType === "black")
{
listw = $("#list-wildcard");
}
if(fade) {
list.fadeOut(100);
}
@@ -48,7 +53,7 @@ function refresh(fade) {
// Wildcard entry
// remove leading *
entry = entry.substr(1, entry.length - 1);
list.append(
listw.append(
"<li id=\"" + index + "\" class=\"list-group-item clearfix\">" + entry +
"<button class=\"btn btn-danger btn-xs pull-right\" type=\"button\">" +
"<span class=\"glyphicon glyphicon-trash\"></span></button></li>");