diff --git a/scripts/pi-hole/js/settings.js b/scripts/pi-hole/js/settings.js index c8b7e3f4..2bd41f9f 100644 --- a/scripts/pi-hole/js/settings.js +++ b/scripts/pi-hole/js/settings.js @@ -2,12 +2,13 @@ $(function () { $("[data-mask]").inputmask(); $("[data-static]").on("click", function(){ - var mac = $(this).closest("tr").find('#MAC').text(); - var ip = $(this).closest("tr").find('#IP').text(); - var host = $(this).closest("tr").find('#HOST').text(); - $('input[name="AddHostname"]').val(host); - $('input[name="AddIP"]').val(ip); - $('input[name="AddMAC"]').val(mac); + var row = $(this).closest("tr"); + var mac = row.find("#MAC").text(); + var ip = row.find("#IP").text(); + var host = row.find("#HOST").text(); + $("input[name=\"AddHostname\"]").val(host); + $("input[name=\"AddIP\"]").val(ip); + $("input[name=\"AddMAC\"]").val(mac); }); $("#custom1val").ipAddress({s:4}); diff --git a/settings.php b/settings.php index 60ae1452..e40aeb42 100644 --- a/settings.php +++ b/settings.php @@ -369,7 +369,7 @@ 0){ ?> - +

Specifying the MAC address is mandatory and only one entry per MAC address is allowed. If the IP address is omitted and a host name is given, the IP address will still be generated dynamically and the specified host name will be used. If the host name is omitted, only a static release will be added.