diff --git a/js/pihole/queryads.js b/js/pihole/queryads.js index 26061d42..364534c6 100644 --- a/js/pihole/queryads.js +++ b/js/pihole/queryads.js @@ -5,7 +5,8 @@ function eventsource() { { return; } - var source = new EventSource("php/queryads.php?domain="+domain.val()); + var host = window.location.host; + var source = new EventSource("http://"+host+"/admin/php/queryads.php?domain="+domain.val()); // Reset and show field ta.empty(); diff --git a/php/queryads.php b/php/queryads.php index e77ee223..eedb4a22 100644 --- a/php/queryads.php +++ b/php/queryads.php @@ -1,7 +1,4 @@