diff options
author | Ermal <eri@pfsense.org> | 2010-03-19 17:35:59 +0000 |
---|---|---|
committer | Ermal <eri@pfsense.org> | 2010-03-19 17:35:59 +0000 |
commit | 40050fabb4edb5c952f681cbe759452fecf83903 (patch) | |
tree | 22c4871c4e03a0dbc7d30c5b8eaf44368052d406 /usr | |
parent | 541989d59005d5b9250d4d51f55cbc4da218937a (diff) | |
download | pfsense-40050fabb4edb5c952f681cbe759452fecf83903.zip pfsense-40050fabb4edb5c952f681cbe759452fecf83903.tar.gz |
Use alias style when creating aliases in wizards.
Diffstat (limited to 'usr')
-rwxr-xr-x | usr/local/www/wizard.php | 16 |
1 files changed, 5 insertions, 11 deletions
diff --git a/usr/local/www/wizard.php b/usr/local/www/wizard.php index 4dfbde2..d91290b 100755 --- a/usr/local/www/wizard.php +++ b/usr/local/www/wizard.php @@ -412,12 +412,12 @@ function showchange() { echo "<td width=\"22%\" align=\"right\" class=\"vncellreq\">\n"; echo fixup_string($field['name']); echo ":</td>\n"; - $inputaliases[] = $name; } if(!$field['dontcombinecells']) echo "<td class=\"vtable\">\n"; - echo "<input class='formfld unknown' autocomplete='off' class='formfldalias' id='" . $name . "' name='" . $name . "' value='" . $value . "'"; + $inputaliases[] = $name; + echo "<input class='formfldalias' autocomplete='off' class='formfldalias' id='" . $name . "' name='" . $name . "' value='" . $value . "'"; if($field['size']) echo " size='" . $field['size'] . "' "; if($field['validate']) @@ -776,19 +776,13 @@ function showchange() { $aliasesaddr = ""; if($config['aliases']['alias'] <> "" and is_array($config['aliases']['alias'])) foreach($config['aliases']['alias'] as $alias_name) { - if(!stristr($alias_name['address'], ".")) { - if($isfirst == 1) $aliases .= ","; + if($isfirst == 1) + $aliases .= ","; $aliases .= "'" . $alias_name['name'] . "'"; $isfirst = 1; - } else { - if($addrisfirst == 1) $aliasesaddr .= ","; - $aliasesaddr .= "'" . $alias_name['name'] . "'"; - $addrisfirst = 1; - } } ?> - var addressarray=new Array(<?php echo $aliasesaddr; ?>); var customarray=new Array(<?php echo $aliases; ?>); window.onload = function () { @@ -796,7 +790,7 @@ function showchange() { <?php $counter=0; foreach($inputaliases as $alias) { - echo "var oTextbox$counter = new AutoSuggestControl(document.getElementById(\"$alias\"), new StateSuggestions(addressarray));\n"; + echo "var oTextbox$counter = new AutoSuggestControl(document.getElementById(\"$alias\"), new StateSuggestions(customarray));\n"; $counter++; } ?> |