diff options
Diffstat (limited to 'usr/local/www/services_unbound.php')
-rw-r--r-- | usr/local/www/services_unbound.php | 127 |
1 files changed, 64 insertions, 63 deletions
diff --git a/usr/local/www/services_unbound.php b/usr/local/www/services_unbound.php index 16bacc9..1921426 100644 --- a/usr/local/www/services_unbound.php +++ b/usr/local/www/services_unbound.php @@ -113,13 +113,14 @@ if ($_POST) { } } +$closehead = false; $pgtitle = array(gettext("Services"),gettext("DNS Resolver")); include_once("head.inc"); ?> <script type="text/javascript"> -<!-- +//<![CDATA[ function enable_change(enable_over) { var endis; endis = !(jQuery('#enable').is(":checked") || enable_over); @@ -129,15 +130,16 @@ function show_advanced_dns() { jQuery("#showadv").show(); jQuery("#showadvbox").hide(); } -//--> +//]]> </script> +</head> <body> <?php include("fbegin.inc"); ?> <form action="services_unbound.php" method="post" name="iform" id="iform"> <?php if ($input_errors) print_input_errors($input_errors); ?> <?php if ($savemsg) print_info_box($savemsg); ?> -<?php if (is_subsystem_dirty('unbound')): ?><p> +<?php if (is_subsystem_dirty('unbound')): ?><br/> <?php print_info_box_np(gettext("The configuration for the DNS Resolver, has been changed") . ".<br />" . gettext("You must apply the changes in order for them to take effect."));?><br /> <?php endif; ?> <table width="100%" border="0" cellpadding="0" cellspacing="0" summary="services unbound"> @@ -156,7 +158,7 @@ function show_advanced_dns() { <tr> <td id="mainarea"> <div class="tabcont"> - <table width="100%" border="0" cellpadding="6" cellspacing="0"> + <table width="100%" border="0" cellpadding="6" cellspacing="0" summary="main area"> <tbody> <tr> <td colspan="2" valign="top" class="listtopic"><?=gettext("General DNS Resolver Options");?></td> @@ -164,16 +166,16 @@ function show_advanced_dns() { <tr> <td width="22%" valign="top" class="vncellreq"><?=gettext("Enable");?></td> <td width="78%" class="vtable"><p> - <input name="enable" type="checkbox" id="enable" value="yes" <?php if ($pconfig['enable'] == "yes") echo "checked";?> onClick="enable_change(false)"> + <input name="enable" type="checkbox" id="enable" value="yes" <?php if ($pconfig['enable'] == "yes") echo "checked=\"checked\"";?> onclick="enable_change(false)" /> <strong><?=gettext("Enable DNS Resolver");?><br /> - </strong></p></td> + </strong></p> </td> </tr> <tr> <td width="22%" valign="top" class="vncellreq"><?=gettext("Listen Port");?></td> <td width="78%" class="vtable"> <p> - <input name="port" type="text" id="port" size="6" <?php if ($pconfig['port']) echo "value=\"{$pconfig['port']}\"";?>> + <input name="port" type="text" id="port" size="6" <?php if ($pconfig['port']) echo "value=\"{$pconfig['port']}\"";?> /> <br /><br /> <?=gettext("The port used for responding to DNS queries. It should normally be left blank unless another service needs to bind to TCP/UDP port 53.");?> </p> @@ -232,7 +234,7 @@ function show_advanced_dns() { <tr> <td width="22%" valign="top" class="vncellreq"><?=gettext("DNSSEC");?></td> <td width="78%" class="vtable"><p> - <input name="dnssec" type="checkbox" id="dnssec" value="yes" <?php echo (isset($pconfig['dnssec']) ? "checked" : "");?>/> + <input name="dnssec" type="checkbox" id="dnssec" value="yes" <?php echo (isset($pconfig['dnssec']) ? "checked=\"checked\"" : "");?> /> <strong><?=gettext("Enable DNSSEC Support");?><br /> </strong></p> </td> @@ -240,14 +242,14 @@ function show_advanced_dns() { <tr> <td width="22%" valign="top" class="vncellreq"><?=gettext("DNS Query Forwarding");?></td> <td width="78%" class="vtable"><p> - <input name="forwarding" type="checkbox" id="forwarding" value="yes" <?php echo (isset($pconfig['forwarding']) ? "checked" : "");?>/> + <input name="forwarding" type="checkbox" id="forwarding" value="yes" <?php echo (isset($pconfig['forwarding']) ? "checked=\"checked\"" : "");?> /> <strong><?=gettext("Enable Forwarding Mode");?></strong><br /></p> </td> </tr> <tr> <td width="22%" valign="top" class="vncellreq"><?=gettext("DHCP Registration");?></td> <td width="78%" class="vtable"><p> - <input name="regdhcp" type="checkbox" id="regdhcp" value="yes" <?php if ($pconfig['regdhcp'] === true) echo "checked";?>> + <input name="regdhcp" type="checkbox" id="regdhcp" value="yes" <?php if ($pconfig['regdhcp'] === true) echo "checked=\"checked\"";?> /> <strong><?=gettext("Register DHCP leases in the DNS Resolver");?><br /> </strong><?php printf(gettext("If this option is set, then machines that specify". " their hostname when requesting a DHCP lease will be registered". @@ -259,7 +261,7 @@ function show_advanced_dns() { <tr> <td width="22%" valign="top" class="vncellreq"><?=gettext("Static DHCP");?></td> <td width="78%" class="vtable"><p> - <input name="regdhcpstatic" type="checkbox" id="regdhcpstatic" value="yes" <?php if ($pconfig['regdhcpstatic'] === true) echo "checked";?>> + <input name="regdhcpstatic" type="checkbox" id="regdhcpstatic" value="yes" <?php if ($pconfig['regdhcpstatic'] === true) echo "checked=\"checked\"";?> /> <strong><?=gettext("Register DHCP static mappings in the DNS Resolver");?><br /> </strong><?php printf(gettext("If this option is set, then DHCP static mappings will ". "be registered in the DNS Resolver, so that their name can be ". @@ -270,28 +272,27 @@ function show_advanced_dns() { <tr> <td width="22%" valign="top" class="vncellreq"><?=gettext("TXT Comment Support");?></td> <td width="78%" class="vtable"><p> - <input name="txtsupport" type="checkbox" id="txtsupport" value="yes" <?php echo (isset($pconfig['txtsupport']) ? "checked" : "");?>/> + <input name="txtsupport" type="checkbox" id="txtsupport" value="yes" <?php echo (isset($pconfig['txtsupport']) ? "checked=\"checked\"" : "");?> /> <strong><?=gettext("If this option is set, then any descriptions associated with Host entries and DHCP Static mappings will create a corresponding TXT record.");?><br /> </strong></p> </td> </tr> <tr> <td width="22%" valign="top" class="vncellreq"><?=gettext("Advanced");?></td> - <td width="78%" class="vtable"><p> + <td width="78%" class="vtable"> <div id="showadvbox" <?php if ($pconfig['custom_options']) echo "style='display:none'"; ?>> - <input type="button" onClick="show_advanced_dns()" value="<?=gettext("Advanced"); ?>" /> - <?=gettext("Show advanced option");?></a> + <input type="button" onClick="show_advanced_dns()" value="<?=gettext("Advanced"); ?>" /> - <?=gettext("Show advanced option");?> </div> <div id="showadv" <?php if (empty($pconfig['custom_options'])) echo "style='display:none'"; ?>> <strong><?=gettext("Advanced");?><br /></strong> <textarea rows="6" cols="78" name="custom_options" id="custom_options"><?=htmlspecialchars($pconfig['custom_options']);?></textarea><br /> <?=gettext("Enter any additional options you would like to add to the DNS Resolver configuration here, separated by a space or newline"); ?><br /> </div> - </p> </td> </tr> <tr> <td colspan="2"> - <input name="submit" type="submit" class="formbtn" value="<?=gettext("Save"); ?>" onclick="enable_change(true)"> + <input name="submit" type="submit" class="formbtn" value="<?=gettext("Save"); ?>" onclick="enable_change(true)" /> </td> </tr> </tbody> @@ -315,7 +316,7 @@ function show_advanced_dns() { </span></p> <br /> -<table width="100%" border="0" cellpadding="0" cellspacing="0" class="tabcont"> +<table width="100%" border="0" cellpadding="0" cellspacing="0" class="tabcont" summary="host overrides"> <tr> <td colspan="5" valign="top" class="listtopic"><?=gettext("Host Overrides");?></td> </tr> @@ -326,7 +327,7 @@ function show_advanced_dns() { </td> </tr> </table> -<table width="100%" border="0" cellpadding="0" cellspacing="0" class="tabcont sortable"> +<table width="100%" border="0" cellpadding="0" cellspacing="0" class="tabcont sortable" summary="results"> <thead> <tr> <td width="20%" class="listhdrr"><?=gettext("Host");?></td> @@ -334,15 +335,28 @@ function show_advanced_dns() { <td width="20%" class="listhdrr"><?=gettext("IP");?></td> <td width="25%" class="listhdr"><?=gettext("Description");?></td> <td width="10%" class="list"> - <table border="0" cellspacing="0" cellpadding="1"> + <table border="0" cellspacing="0" cellpadding="1" summary="add"> <tr> <td width="17"></td> - <td valign="middle"><a href="services_unbound_host_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0"></a></td> + <td valign="middle"><a href="services_unbound_host_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0" alt="add" /></a></td> </tr> </table> </td> </tr> </thead> + <tfoot> + <tr> + <td class="list" colspan="4"></td> + <td class="list"> + <table border="0" cellspacing="0" cellpadding="1" summary="add"> + <tr> + <td width="17"></td> + <td valign="middle"><a href="services_unbound_host_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0" alt="add" /></a></td> + </tr> + </table> + </td> + </tr> + </tfoot> <tbody> <?php $i = 0; foreach ($a_hosts as $hostent): ?> <tr> @@ -358,58 +372,57 @@ function show_advanced_dns() { <td class="listbg" ondblclick="document.location='services_unbound_host_edit.php?id=<?=$i;?>';"> <?=htmlspecialchars($hostent['descr']);?> </td> - <td valign="middle" nowrap class="list"> - <table border="0" cellspacing="0" cellpadding="1"> + <td valign="middle" class="list nowrap"> + <table border="0" cellspacing="0" cellpadding="1" summary="icons"> <tr> - <td valign="middle"><a href="services_unbound_host_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a></td> - <td><a href="services_unbound.php?type=host&act=del&id=<?=$i;?>" onclick="return confirm('<?=gettext("Do you really want to delete this host?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td> + <td valign="middle"><a href="services_unbound_host_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0" alt="edit" /></a></td> + <td><a href="services_unbound.php?type=host&act=del&id=<?=$i;?>" onclick="return confirm('<?=gettext("Do you really want to delete this host?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0" alt="delete" /></a></td> </tr> </table> </tr> <?php $i++; endforeach; ?> + <tr style="display:none"><td></td></tr> </tbody> - <tfoot> - <tr> - <td class="list" colspan="4"></td> - <td class="list"> - <table border="0" cellspacing="0" cellpadding="1"> - <tr> - <td width="17"></td> - <td valign="middle"><a href="services_unbound_host_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0"></a></td> - </tr> - </table> - </td> - </tr> - </tfoot> </table> <br /> -<table width="100%" border="0" cellpadding="0" cellspacing="0" class="tabcont"> +<table width="100%" border="0" cellpadding="0" cellspacing="0" class="tabcont" summary="domain overrides"> <tr> <td colspan="5" valign="top" class="listtopic"><?=gettext("Domain Overrides");?></td> </tr> <tr> - <tr> - <td><p><?=gettext("Entries in this area override an entire domain by specifying an". - " authoritative DNS server to be queried for that domain.");?></p></td> - </tr> + <td><p><?=gettext("Entries in this area override an entire domain by specifying an". + " authoritative DNS server to be queried for that domain.");?></p></td> </tr> </table> -<table width="100%" border="0" cellpadding="0" cellspacing="0" class="tabcont sortable"> +<table width="100%" border="0" cellpadding="0" cellspacing="0" class="tabcont sortable" summary="results"> <thead> <tr> <td width="35%" class="listhdrr"><?=gettext("Domain");?></td> <td width="20%" class="listhdrr"><?=gettext("IP");?></td> <td width="35%" class="listhdr"><?=gettext("Description");?></td> <td width="10%" class="list"> - <table border="0" cellspacing="0" cellpadding="1"> + <table border="0" cellspacing="0" cellpadding="1" summary="add"> <tr> - <td width="17" heigth="17"></td> - <td><a href="services_unbound_domainoverride_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0"></a></td> + <td width="17" height="17"></td> + <td><a href="services_unbound_domainoverride_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0" alt="add" /></a></td> </tr> </table> </td> </tr> </thead> + <tfoot> + <tr> + <td class="list" colspan="3"></td> + <td class="list"> + <table border="0" cellspacing="0" cellpadding="1" summary="add"> + <tr> + <td width="17" height="17"></td> + <td><a href="services_unbound_domainoverride_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0" alt="add" /></a></td> + </tr> + </table> + </td> + </tr> + </tfoot> <tbody> <?php $i = 0; foreach ($a_domainOverrides as $doment): ?> <tr> @@ -422,30 +435,18 @@ function show_advanced_dns() { <td class="listbg"> <?=htmlspecialchars($doment['descr']);?> </td> - <td valign="middle" nowrap class="list"> <a href="services_unbound_domainoverride_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a> - <a href="services_unbound.php?act=del&type=doverride&id=<?=$i;?>" onclick="return confirm('<?=gettext("Do you really want to delete this domain override?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td> + <td valign="middle" class="list nowrap"> <a href="services_unbound_domainoverride_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0" alt="edit" /></a> + <a href="services_unbound.php?act=del&type=doverride&id=<?=$i;?>" onclick="return confirm('<?=gettext("Do you really want to delete this domain override?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0" alt="delete" /></a></td> </tr> <?php $i++; endforeach; ?> + <tr style="display:none"><td></td></tr> </tbody> - <tfoot> - <tr> - <td class="list" colspan="3"></td> - <td class="list"> - <table border="0" cellspacing="0" cellpadding="1"> - <tr> - <td width="17" heigth="17"></td> - <td><a href="services_unbound_domainoverride_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0"></a></td> - </tr> - </table> - </td> - </tr> - </tfoot> </table> </form> <script type="text/javascript"> -<!-- +//<![CDATA[ enable_change(false); -//--> +//]]> </script> <?php include("fend.inc"); ?> </body> |