From 0371f870a8ce31ccf25213afd9455dd0df60bb00 Mon Sep 17 00:00:00 2001 From: DL6ER Date: Wed, 15 Nov 2023 12:08:54 +0100 Subject: [PATCH 1/3] Domains/Regex must be either space or newline separated when adding multiple at once. It is not possible to use comma as this has a special meaning in the regex world Signed-off-by: DL6ER --- scripts/pi-hole/js/groups-domains.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/pi-hole/js/groups-domains.js b/scripts/pi-hole/js/groups-domains.js index c430e560..93c04c2d 100644 --- a/scripts/pi-hole/js/groups-domains.js +++ b/scripts/pi-hole/js/groups-domains.js @@ -509,7 +509,7 @@ function addDomain() { // Check if the user wants to add multiple domains (space or newline separated) // If so, split the input and store it in an array - var domains = utils.escapeHtml(domainEl.val()).split(/[\s,]+/); + var domains = utils.escapeHtml(domainEl.val()).split(/\s+/); // Remove empty elements domains = domains.filter(function (el) { return el !== ""; From fba38b32bda773c9c19eaccf67f0ec6426717258 Mon Sep 17 00:00:00 2001 From: DL6ER Date: Thu, 16 Nov 2023 12:42:22 +0100 Subject: [PATCH 2/3] Add space-separation for multi-add domains Signed-off-by: DL6ER --- groups-domains.lp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/groups-domains.lp b/groups-domains.lp index 784065ef..1fb0a7c0 100644 --- a/groups-domains.lp +++ b/groups-domains.lp @@ -86,7 +86,8 @@ mg.include('scripts/pi-hole/lua/header_authenticated.lp','r')

Note:
The domain or regex filter will be automatically assigned to the Default Group.
- Other groups can optionally be assigned in the list below (using Group assignment). + Other groups can optionally be assigned in the list below (using Group assignment).
+ You can add multiple entries at once by separating them with spaces (e.g. example.com example.org).

-

You can select an existing client or add a custom one by typing into the field above and confirming your entry with ⏎.

+

You can select an existing client or add a custom one by typing into the field above and confirming your entry with ⏎. + Multiple clients can be added by separating each client with a space or comma.

Clients may be described either by their IP addresses (IPv4 and IPv6 are supported), IP subnets (CIDR notation, like 192.168.2.0/24), their MAC addresses (like 12:34:56:78:9A:BC), diff --git a/groups-lists.lp b/groups-lists.lp index 02f36be9..7671a5db 100644 --- a/groups-lists.lp +++ b/groups-lists.lp @@ -30,7 +30,7 @@ mg.include('scripts/pi-hole/lua/header_authenticated.lp','r')

- +
@@ -42,7 +42,7 @@ mg.include('scripts/pi-hole/lua/header_authenticated.lp','r') Hints:
  1. Please run pihole -g or update your gravity list online after modifying your lists.
  2. -
  3. Multiple lists can be added by separating each unique URL with a space
  4. +
  5. Multiple lists can be added by separating each unique URL with a space or comma
  6. Click on the icon in the first column to get additional information about your lists. The icons correspond to the health of the list.