summaryrefslogtreecommitdiffstats
path: root/usr/local
diff options
context:
space:
mode:
Diffstat (limited to 'usr/local')
-rwxr-xr-xusr/local/www/services_captiveportal.php7
1 files changed, 4 insertions, 3 deletions
diff --git a/usr/local/www/services_captiveportal.php b/usr/local/www/services_captiveportal.php
index 785c1ba..472fccd 100755
--- a/usr/local/www/services_captiveportal.php
+++ b/usr/local/www/services_captiveportal.php
@@ -445,10 +445,11 @@ function enable_change(enable_change) {
<select name="cinterface[]" multiple="true" size="<?php echo count($config['interfaces']); ?>" class="formselect" id="cinterface">
<?php
$interfaces = get_configured_interface_with_descr();
+ $cselected = explode(",", $pconfig['cinterface']);
foreach ($interfaces as $iface => $ifacename): ?>
- <option value="<?=$iface;?>" <?php if (stristr($pconfig['cinterface'], $iface)) echo "selected"; ?>>
- <?=htmlspecialchars($ifacename);?>
- </option>
+ <option value="<?=$iface;?>" <?php if (in_array($iface, $cselected)) echo "selected"; ?>>
+ <?=htmlspecialchars($ifacename);?>
+ </option>
<?php endforeach; ?>
</select> <br>
<span class="vexpl"><?=gettext("Select the interface(s) to enable for captive portal."); ?></span></td>
OpenPOWER on IntegriCloud