summaryrefslogtreecommitdiffstats
path: root/usr/local/www
diff options
context:
space:
mode:
authorPhil Davis <phil.davis@world.inf.org>2013-07-21 10:31:33 -0700
committerPhil Davis <phil.davis@world.inf.org>2013-07-21 10:31:33 -0700
commit09a68ea4a0df0e9af1f3659ebe0b407cac608ee5 (patch)
tree91f988cb9db2e4d1576cb08da066677e8dd0de8e /usr/local/www
parent4b8628b59527b8c483328912f72d0f231316d406 (diff)
downloadpfsense-09a68ea4a0df0e9af1f3659ebe0b407cac608ee5.zip
pfsense-09a68ea4a0df0e9af1f3659ebe0b407cac608ee5.tar.gz
When adding Port or URL alias default the alias type
When viewing the Port or URL aliases tab, and pressing "+" (add), make the default alias type match the Port or URL tab from which the user pressed "+".
Diffstat (limited to 'usr/local/www')
-rwxr-xr-xusr/local/www/firewall_aliases_edit.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr/local/www/firewall_aliases_edit.php b/usr/local/www/firewall_aliases_edit.php
index 1b0a194..51b8fff 100755
--- a/usr/local/www/firewall_aliases_edit.php
+++ b/usr/local/www/firewall_aliases_edit.php
@@ -3,7 +3,7 @@
/*
firewall_aliases_edit.php
Copyright (C) 2004 Scott Ullrich
- Copyright (C) 2009 Ermal Luçi
+ Copyright (C) 2009 Ermal Luçi
Copyright (C) 2010 Jim Pingle
All rights reserved.
@@ -674,9 +674,9 @@ if (empty($tab)) {
<select name="type" class="formselect" id="type" onchange="update_box_type(); typesel_change();">
<option value="host" <?php if ($pconfig['type'] == "host") echo "selected=\"selected\""; ?>><?=gettext("Host(s)"); ?></option>
<option value="network" <?php if ($pconfig['type'] == "network") echo "selected=\"selected\""; ?>><?=gettext("Network(s)"); ?></option>
- <option value="port" <?php if ($pconfig['type'] == "port") echo "selected=\"selected\""; ?>><?=gettext("Port(s)"); ?></option>
+ <option value="port" <?php if (($pconfig['type'] == "port") || (empty($pconfig['type']) && ($tab == "port"))) echo "selected=\"selected\""; ?>><?=gettext("Port(s)"); ?></option>
<!--<option value="openvpn" <?php if ($pconfig['type'] == "openvpn") echo "selected=\"selected\""; ?>><?=gettext("OpenVPN Users"); ?></option> -->
- <option value="url" <?php if ($pconfig['type'] == "url") echo "selected=\"selected\""; ?>><?=gettext("URL (IPs)");?></option>
+ <option value="url" <?php if (($pconfig['type'] == "url") || (empty($pconfig['type']) && ($tab == "url"))) echo "selected=\"selected\""; ?>><?=gettext("URL (IPs)");?></option>
<option value="url_ports" <?php if ($pconfig['type'] == "url_ports") echo "selected=\"selected\""; ?>><?=gettext("URL (Ports)");?></option>
<option value="urltable" <?php if ($pconfig['type'] == "urltable") echo "selected=\"selected\""; ?>><?=gettext("URL Table (IPs)"); ?></option>
<option value="urltable_ports" <?php if ($pconfig['type'] == "urltable_ports") echo "selected=\"selected\""; ?>><?=gettext("URL Table (Ports)"); ?></option>
OpenPOWER on IntegriCloud