diff --git a/scripts/pi-hole/php/savesettings.php b/scripts/pi-hole/php/savesettings.php
index e65a7a61..ddda5138 100644
--- a/scripts/pi-hole/php/savesettings.php
+++ b/scripts/pi-hole/php/savesettings.php
@@ -355,9 +355,18 @@ function validDomain($domain_name)
$error .= "Lease time ".$leasetime." is invalid!
";
}
+ if(isset($_POST["useIPv6"]))
+ {
+ $ipv6 = "useIPv6";
+ }
+ else
+ {
+ $ipv6 = "noIPv6";
+ }
+
if(!strlen($error))
{
- exec("sudo pihole -a enabledhcp ".$from." ".$to." ".$router." ".$leasetime." ".$domain);
+ exec("sudo pihole -a enabledhcp ".$from." ".$to." ".$router." ".$leasetime." ".$domain." ".$ipv6);
$success .= "The DHCP server has been activated";
}
}
diff --git a/settings.php b/settings.php
index 175af9f1..9fd34070 100644
--- a/settings.php
+++ b/settings.php
@@ -132,6 +132,15 @@
{
$DHCPleasetime = 24;
}
+ if(isset($setupVars["DHCP_IPV6"]))
+ {
+ $DHCPIPv6 = $setupVars["DHCP_IPV6"];
+ }
+ else
+ {
+ $DHCPIPv6 = true;
+ }
+
}
else
{
@@ -149,6 +158,7 @@
$DHCProuter = "";
}
$DHCPleasetime = 24;
+ $DHCPIPv6 = true;
}
if(isset($setupVars["PIHOLE_DOMAIN"])){
$piHoleDomain = $setupVars["PIHOLE_DOMAIN"];
@@ -205,6 +215,11 @@