diff --git a/.pullapprove.yml b/.pullapprove.yml index dfe83654..42d3b2fb 100644 --- a/.pullapprove.yml +++ b/.pullapprove.yml @@ -35,4 +35,4 @@ groups: - master required: 4 teams: - - admin + - approvers diff --git a/db_queries.php b/db_queries.php index 189c97cd..a2441b58 100644 --- a/db_queries.php +++ b/db_queries.php @@ -99,7 +99,7 @@ $token = $_SESSION['token'];
-

Recent Queries

+

Recent Queries

diff --git a/list.php b/list.php index 9b71bd74..5efde479 100644 --- a/list.php +++ b/list.php @@ -11,7 +11,7 @@ $list = $_GET['l']; if($list !== "white" && $list !== "black"){ echo "Invalid list parameter"; - require "footer.php"; + require "scripts/pi-hole/php/footer.php"; die(); } diff --git a/scripts/pi-hole/js/db_lists.js b/scripts/pi-hole/js/db_lists.js index 9a7cdfbc..75a21746 100644 --- a/scripts/pi-hole/js/db_lists.js +++ b/scripts/pi-hole/js/db_lists.js @@ -90,7 +90,7 @@ function updateTopClientsChart() { var url = clientname; percentage = data.top_sources[client] / sum * 100.0; clienttable.append(" " + url + - " " + data.top_sources[client] + "
" + data.top_sources[client] + "
"); } @@ -128,7 +128,7 @@ function updateTopDomainsChart() { percentage = data.top_domains[domain] / sum * 100.0; domaintable.append(" " + domain + - " " + data.top_domains[domain] + "
" + data.top_domains[domain] + "
"); } @@ -165,7 +165,7 @@ function updateTopAdsChart() { } percentage = data.top_ads[ad] / sum * 100.0; - adtable.append(" " + ad + " " + data.top_ads[ad] + "
"); + adtable.append(" " + ad + " " + data.top_ads[ad] + "
"); } } diff --git a/scripts/pi-hole/js/list.js b/scripts/pi-hole/js/list.js index 1b01387c..664d64b2 100644 --- a/scripts/pi-hole/js/list.js +++ b/scripts/pi-hole/js/list.js @@ -143,8 +143,7 @@ function add(arg) { method: "post", data: {"domain":domain.val(), "list":locallistType, "token":token}, success: function(response) { - if (response.indexOf("not a valid argument") >= 0 || - response.indexOf("is not a valid domain") >= 0) { + if (response.indexOf("] Pi-hole blocking is ") === -1) { alFailure.show(); err.html(response); alFailure.delay(4000).fadeOut(2000, function() { diff --git a/scripts/pi-hole/php/auth.php b/scripts/pi-hole/php/auth.php index a8a64e33..22cb459c 100644 --- a/scripts/pi-hole/php/auth.php +++ b/scripts/pi-hole/php/auth.php @@ -119,7 +119,7 @@ function check_csrf($token) { function check_domain() { if(isset($_POST['domain'])){ - $domains = explode(" ",$_POST['domain']); + $domains = preg_split('\s+', $_POST['domain']); foreach($domains as $domain) { $validDomain = is_valid_domain_name($domain); diff --git a/scripts/pi-hole/php/header.php b/scripts/pi-hole/php/header.php index f0387167..767e1a47 100644 --- a/scripts/pi-hole/php/header.php +++ b/scripts/pi-hole/php/header.php @@ -420,10 +420,10 @@ if($auth) {
  • active"> - Long term data + Long term data
      class="active"> @@ -459,10 +459,10 @@ if($auth) {
    • hidden="true"> - Disable    + Disable   
      • @@ -499,10 +499,10 @@ if($auth) {
      • active"> - Tools + Tools
          diff --git a/scripts/pi-hole/php/update_checker.php b/scripts/pi-hole/php/update_checker.php index abcfc9de..6629b6a6 100644 --- a/scripts/pi-hole/php/update_checker.php +++ b/scripts/pi-hole/php/update_checker.php @@ -42,14 +42,14 @@ $FTL_current = exec("pihole-FTL version"); $versionfile = "../versions"; $check_version = false; +$date = date_create(); +$timestamp = date_timestamp_get($date); // Check version if version buffer file does not exist if(is_readable($versionfile)) { // Obtain latest time stamp from buffer file $versions = explode(",",file_get_contents($versionfile)); - $date = date_create(); - $timestamp = date_timestamp_get($date); // Is last check for updates older than 30 minutes? if($timestamp >= intval($versions[0]) + 1800) diff --git a/style/pi-hole.css b/style/pi-hole.css index 6f090058..18b88fe4 100644 --- a/style/pi-hole.css +++ b/style/pi-hole.css @@ -34,3 +34,9 @@ a.lookatme { -webkit-animation-iteration-count: infinite; animation-iteration-count: infinite; } +#all-queries { + table-layout: fixed; +} +#all-queries tbody { + word-wrap: break-word; +}