mirror of
https://github.com/pi-hole/web.git
synced 2026-02-15 07:25:39 +00:00
Extend query log and API to be able to handle requests limited to specific forward destinations and query types
Signed-off-by: DL6ER <dl6er@dl6er.de>
This commit is contained in:
10
api_FTL.php
10
api_FTL.php
@@ -262,6 +262,16 @@ else
|
||||
// Get specific client only
|
||||
sendRequestFTL("getallqueries-client ".$_GET['client']);
|
||||
}
|
||||
else if(isset($_GET['querytype']))
|
||||
{
|
||||
// Get specific query type only
|
||||
sendRequestFTL("getallqueries-qtype ".$_GET['querytype']);
|
||||
}
|
||||
else if(isset($_GET['forwarddest']))
|
||||
{
|
||||
// Get specific forward destination only
|
||||
sendRequestFTL("getallqueries-forward ".$_GET['forwarddest']);
|
||||
}
|
||||
else if(is_numeric($_GET['getAllQueries']))
|
||||
{
|
||||
sendRequestFTL("getallqueries (".$_GET['getAllQueries'].")");
|
||||
|
||||
@@ -136,6 +136,14 @@ $(document).ready(function() {
|
||||
{
|
||||
APIstring += "&domain="+GETDict["domain"];
|
||||
}
|
||||
else if("querytype" in GETDict)
|
||||
{
|
||||
APIstring += "&querytype="+GETDict["querytype"];
|
||||
}
|
||||
else if("forwarddest" in GETDict)
|
||||
{
|
||||
APIstring += "&forwarddest="+GETDict["forwarddest"];
|
||||
}
|
||||
// If we don't ask filtering and also not for all queries, just request the most recent 100 queries
|
||||
else if(!("all" in GETDict))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user