mirror of
https://github.com/pi-hole/web.git
synced 2025-12-26 05:26:19 +00:00
* CORS was required to auth (bug) - fixed * Logging defaults to the default lighttpd error log * Overridable error log location to support alpine/nginx container or power users * Put the repeated code into a include for sub/add, auth.php * Error logs say what failed much better now * VIRTUAL_HOST should theoretically allow custom hostnames for CORS
14 lines
243 B
PHP
14 lines
243 B
PHP
<?php
|
|
require('auth.php');
|
|
|
|
switch($_POST['list']) {
|
|
case "white":
|
|
echo exec("sudo pihole -w -q ${_POST['domain']}");
|
|
break;
|
|
case "black":
|
|
echo exec("sudo pihole -b -q ${_POST['domain']}");
|
|
break;
|
|
}
|
|
|
|
?>
|