diff options
-rw-r--r-- | etc/inc/unbound.inc | 2 | ||||
-rw-r--r-- | usr/local/www/services_unbound.php | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/etc/inc/unbound.inc b/etc/inc/unbound.inc index 68f60bb..0cc6046 100644 --- a/etc/inc/unbound.inc +++ b/etc/inc/unbound.inc @@ -485,7 +485,7 @@ function unbound_add_host_entries() { $host_entries .= "local-data: \"{$host['host']}{$host['domain']} IN AAAA {$host['ip']}\"\n"; else $host_entries .= "local-data: \"{$host['host']}{$host['domain']} IN A {$host['ip']}\"\n"; - if (!empty($host['descr']) && $dnscfg['txtsupport'] == 'on') + if (!empty($host['descr']) && isset($config['unbound']['txtsupport'])) $host_entries .= "local-data: '{$host['host']}{$host['domain']} TXT \"".addslashes($host['descr'])."\"'\n"; // Do not add duplicate entries diff --git a/usr/local/www/services_unbound.php b/usr/local/www/services_unbound.php index b81d60f..6487c7b 100644 --- a/usr/local/www/services_unbound.php +++ b/usr/local/www/services_unbound.php @@ -49,6 +49,7 @@ $pconfig['dnssec'] = isset($config['unbound']['dnssec']); $pconfig['forwarding'] = isset($config['unbound']['forwarding']); $pconfig['regdhcp'] = isset($config['unbound']['regdhcp']); $pconfig['regdhcpstatic'] = isset($config['unbound']['regdhcpstatic']); +$pconfig['txtsupport'] = isset($config['unbound']['txtsupport']); if(!is_array($config['unbound'])) $config['unbound'] = array(); @@ -89,6 +90,7 @@ if ($_POST) { $a_unboundcfg['forwarding'] = ($_POST['forwarding']) ? true : false; $a_unboundcfg['regdhcp'] = ($_POST['regdhcp']) ? true : false; $a_unboundcfg['regdhcpstatic'] = ($_POST['regdhcpstatic']) ? true : false; + $a_unboundcfg['txtsupport'] = ($_POST['txtsupport']) ? true : false; if (is_array($_POST['active_interface'])) $a_unboundcfg['active_interface'] = implode(",", $_POST['active_interface']); else |