summaryrefslogtreecommitdiffstats
path: root/usr/local/www/firewall_aliases_edit.php
diff options
context:
space:
mode:
authorRenato Botelho <garga@FreeBSD.org>2013-04-02 16:22:47 -0300
committerRenato Botelho <garga@FreeBSD.org>2013-04-02 16:22:47 -0300
commit7cbeade191bfb4812c80fc40b72f1cd144d82b8f (patch)
treebe62c379b3daeb7ec40b089f7b69ac7745dce7d1 /usr/local/www/firewall_aliases_edit.php
parent5a815dc7202cdea0d9019babe075a3db9707484d (diff)
downloadpfsense-7cbeade191bfb4812c80fc40b72f1cd144d82b8f.zip
pfsense-7cbeade191bfb4812c80fc40b72f1cd144d82b8f.tar.gz
Preserve all URLs when one of them is invalid
Diffstat (limited to 'usr/local/www/firewall_aliases_edit.php')
-rwxr-xr-xusr/local/www/firewall_aliases_edit.php10
1 files changed, 6 insertions, 4 deletions
diff --git a/usr/local/www/firewall_aliases_edit.php b/usr/local/www/firewall_aliases_edit.php
index bbc4ee9..b455b4f 100755
--- a/usr/local/www/firewall_aliases_edit.php
+++ b/usr/local/www/firewall_aliases_edit.php
@@ -238,16 +238,18 @@ if ($_POST) {
}
if($isfirst == 0) {
/* nothing was found */
- $input_errors[] = gettext("You must provide a valid URL. Could not fetch usable data.");
+ $input_errors[] = sprintf(gettext("You must provide a valid URL. Could not fetch usable data from '%s'."), $_POST['address' . $x]);
$dont_update = true;
- break;
}
$alias['aliasurl'][] = $_POST['address' . $x];
mwexec("/bin/rm -rf {$temp_filename}");
} else {
- $input_errors[] = gettext("You must provide a valid URL.");
+ $address[] = $_POST['address' . $x];
+ $alias['aliasurl'][] = $_POST['address' . $x];
+ if ($_POST["detail{$x}"] <> "")
+ $final_address_details[] = $_POST["detail{$x}"];
+ $input_errors[] = sprintf(gettext("URL '%s' is not valid."), $_POST['address' . $x]);
$dont_update = true;
- break;
}
}
}
OpenPOWER on IntegriCloud