diff options
author | Renato Botelho <garga@FreeBSD.org> | 2014-07-18 10:29:42 -0300 |
---|---|---|
committer | Renato Botelho <garga@FreeBSD.org> | 2014-07-18 10:29:42 -0300 |
commit | 34bb3ffc28b3888a20fa8ee1009c6859d41219b6 (patch) | |
tree | 64a3567453f0210b1aa115df8252d8817090aef0 | |
parent | bee27ca1e762009c3241438c8df0795a9952a95a (diff) | |
parent | 1657cfd2d421087ccd5a229fdfe38175d315a6c0 (diff) | |
download | pfsense-34bb3ffc28b3888a20fa8ee1009c6859d41219b6.zip pfsense-34bb3ffc28b3888a20fa8ee1009c6859d41219b6.tar.gz |
Merge pull request #1237 from N0YB/XHTML_Compliance_System_Menu
-rw-r--r-- | usr/local/www/system_advanced_admin.php | 8 | ||||
-rw-r--r-- | usr/local/www/system_advanced_firewall.php | 9 | ||||
-rw-r--r-- | usr/local/www/system_crlmanager.php | 34 | ||||
-rw-r--r-- | usr/local/www/system_groupmanager.php | 14 | ||||
-rw-r--r-- | usr/local/www/system_usermanager.php | 27 |
5 files changed, 74 insertions, 18 deletions
diff --git a/usr/local/www/system_advanced_admin.php b/usr/local/www/system_advanced_admin.php index 12f10a6..4982b66 100644 --- a/usr/local/www/system_advanced_admin.php +++ b/usr/local/www/system_advanced_admin.php @@ -357,8 +357,12 @@ function prot_change() { if ($pconfig['ssl-certref'] == $cert['refid']) $selected = "selected=\"selected\""; ?> - <option value="<?=$cert['refid'];?>"<?=$selected;?>><?=$cert['descr'];?></option> - <?php endforeach; ?> + <option value="<?=$cert['refid'];?>" <?=$selected;?>><?=$cert['descr'];?></option> + <?php + endforeach; + if (!count($a_cert)) + echo "<option></option>"; + ?> </select> </td> </tr> diff --git a/usr/local/www/system_advanced_firewall.php b/usr/local/www/system_advanced_firewall.php index e3a523d..48e0de4 100644 --- a/usr/local/www/system_advanced_firewall.php +++ b/usr/local/www/system_advanced_firewall.php @@ -324,7 +324,7 @@ function update_description(itemnum) { <option value="conservative"<?php if($config['system']['optimization']=="conservative") echo " selected=\"selected\""; ?>><?=gettext("conservative");?></option> </select> <br /> - <textarea readonly="readonly" cols="60" rows="2" id="info" name="info"style="padding:5px; border:1px dashed #990000; background-color: #ffffff; color: #000000; font-size: 8pt;"></textarea> + <textarea readonly="readonly" cols="60" rows="2" id="info" name="info" style="padding:5px; border:1px dashed #990000; background-color: #ffffff; color: #000000; font-size: 8pt;"></textarea> <script type="text/javascript"> //<![CDATA[ update_description(document.forms[0].optimization.selectedIndex); @@ -537,10 +537,15 @@ function update_description(itemnum) { <select name="tftpinterface[]" multiple="multiple" class="formselect" size="3"> <?php $ifdescs = get_configured_interface_with_descr(); + $rowIndex = 0; foreach ($ifdescs as $ifent => $ifdesc): + $rowIndex++; ?> <option value="<?=$ifent;?>" <?php if (in_array($ifent, $pconfig['tftpinterface'])) echo "selected=\"selected\""; ?>><?=gettext($ifdesc);?></option> -<?php endforeach; ?> +<?php endforeach; + if ($rowIndex == 0) + echo "<option></option>"; + ?> </select> <strong><?=gettext("Choose the interfaces where you want TFTP proxy helper to be enabled.");?></strong> </td> diff --git a/usr/local/www/system_crlmanager.php b/usr/local/www/system_crlmanager.php index 41c623d..35794f6 100644 --- a/usr/local/www/system_crlmanager.php +++ b/usr/local/www/system_crlmanager.php @@ -304,15 +304,20 @@ function method_change() { <td width="78%" class="vtable"> <select name='method' id='method' class="formselect" onchange='method_change()'> <?php + $rowIndex = 0; foreach($crl_methods as $method => $desc): if (($_GET['importonly'] == "yes") && ($method != "existing")) continue; $selected = ""; if ($pconfig['method'] == $method) $selected = "selected=\"selected\""; + $rowIndex++; + ?> + <option value="<?=$method;?>" <?=$selected;?>><?=$desc;?></option> + <?php endforeach; + if ($rowIndex == 0) + echo "<option></option>"; ?> - <option value="<?=$method;?>"<?=$selected;?>><?=$desc;?></option> - <?php endforeach; ?> </select> </td> </tr> @@ -328,13 +333,18 @@ function method_change() { <td width="78%" class="vtable"> <select name='caref' id='caref' class="formselect"> <?php + $rowIndex = 0; foreach($a_ca as $ca): $selected = ""; if ($pconfig['caref'] == $ca['refid']) $selected = "selected=\"selected\""; + $rowIndex++; + ?> + <option value="<?=$ca['refid'];?>" <?=$selected;?>><?=$ca['descr'];?></option> + <?php endforeach; + if ($rowIndex == 0) + echo "<option></option>"; ?> - <option value="<?=$ca['refid'];?>"<?=$selected;?>><?=$ca['descr'];?></option> - <?php endforeach; ?> </select> </td> </tr> @@ -493,15 +503,23 @@ function method_change() { <tr> <td class="listlr" colspan="3" align="center"> <b><?php echo gettext("Choose a Certificate to Revoke"); ?></b>: <select name='certref' id='certref' class="formselect"> - <?php foreach($ca_certs as $cert): ?> + <?php $rowIndex = 0; + foreach($ca_certs as $cert): + $rowIndex++; ?> <option value="<?=$cert['refid'];?>"><?=htmlspecialchars($cert['descr'])?></option> - <?php endforeach; ?> + <?php endforeach; + if ($rowIndex == 0) + echo "<option></option>"; ?> </select> <b><?php echo gettext("Reason");?></b>: <select name='crlreason' id='crlreason' class="formselect"> - <?php foreach($openssl_crl_status as $code => $reason): ?> + <?php $rowIndex = 0; + foreach($openssl_crl_status as $code => $reason): + $rowIndex++; ?> <option value="<?= $code ?>"><?= htmlspecialchars($reason) ?></option> - <?php endforeach; ?> + <?php endforeach; + if ($rowIndex == 0) + echo "<option></option>"; ?> </select> <input name="act" type="hidden" value="addcert" /> <input name="crlref" type="hidden" value="<?=$crl['refid'];?>" /> diff --git a/usr/local/www/system_groupmanager.php b/usr/local/www/system_groupmanager.php index c62a8c8..b2e65f7 100644 --- a/usr/local/www/system_groupmanager.php +++ b/usr/local/www/system_groupmanager.php @@ -299,14 +299,19 @@ function presubmit() { <br /> <select size="10" style="width: 75%" name="notmembers[]" class="formselect" id="notmembers" onchange="clear_selected('members')" multiple="multiple"> <?php + $rowIndex = 0; foreach ($config['system']['user'] as $user): if (is_array($pconfig['members']) && in_array($user['uid'],$pconfig['members'])) continue; + $rowIndex++; ?> <option value="<?=$user['uid'];?>" <?=$selected;?>> <?=htmlspecialchars($user['name']);?> </option> - <?php endforeach; ?> + <?php endforeach; + if ($rowIndex == 0) + echo "<option></option>"; + ?> </select> <br /> </td> @@ -325,14 +330,19 @@ function presubmit() { <br /> <select size="10" style="width: 75%" name="members[]" class="formselect" id="members" onchange="clear_selected('notmembers')" multiple="multiple"> <?php + $rowIndex = 0; foreach ($config['system']['user'] as $user): if (!(is_array($pconfig['members']) && in_array($user['uid'],$pconfig['members']))) continue; + $rowIndex++; ?> <option value="<?=$user['uid'];?>"> <?=htmlspecialchars($user['name']);?> </option> - <?php endforeach; ?> + <?php endforeach; + if ($rowIndex == 0) + echo "<option></option>"; + ?> </select> <br /> </td> diff --git a/usr/local/www/system_usermanager.php b/usr/local/www/system_usermanager.php index cf7db11..6beed3f 100644 --- a/usr/local/www/system_usermanager.php +++ b/usr/local/www/system_usermanager.php @@ -523,16 +523,21 @@ function sshkeyClicked(obj) { <br /> <select size="10" style="width: 75%" name="notgroups[]" class="formselect" id="notgroups" onchange="clear_selected('groups')" multiple="multiple"> <?php + $rowIndex = 0; foreach ($config['system']['group'] as $group): if ($group['gid'] == 1998) /* all users group */ continue; if (is_array($pconfig['groups']) && in_array($group['name'],$pconfig['groups'])) continue; + $rowIndex++; ?> <option value="<?=$group['name'];?>" <?=$selected;?>> <?=htmlspecialchars($group['name']);?> </option> - <?php endforeach; ?> + <?php endforeach; + if ($rowIndex == 0) + echo "<option></option>"; + ?> </select> <br /> </td> @@ -551,18 +556,23 @@ function sshkeyClicked(obj) { <br /> <select size="10" style="width: 75%" name="groups[]" class="formselect" id="groups" onchange="clear_selected('nogroups')" multiple="multiple"> <?php + $rowIndex = 0; if (is_array($pconfig['groups'])) { foreach ($config['system']['group'] as $group): if ($group['gid'] == 1998) /* all users group */ continue; if (!in_array($group['name'],$pconfig['groups'])) continue; + $rowIndex++; ?> <option value="<?=$group['name'];?>"> <?=htmlspecialchars($group['name']);?> </option> <?php endforeach; - } ?> + } + if ($rowIndex == 0) + echo "<option></option>"; + ?> </select> <br /> </td> @@ -718,12 +728,17 @@ function sshkeyClicked(obj) { <td width="78%" class="vtable"> <select name='caref' id='caref' class="formselect" onchange='internalca_change()'> <?php + $rowIndex = 0; foreach( $config['ca'] as $ca): if (!$ca['prv']) continue; + $rowIndex++; ?> <option value="<?=$ca['refid'];?>"><?=$ca['descr'];?></option> - <?php endforeach; ?> + <?php endforeach; + if ($rowIndex == 0) + echo "<option></option>"; + ?> </select> </td> </tr> @@ -736,7 +751,11 @@ function sshkeyClicked(obj) { foreach( $cert_keylens as $len): ?> <option value="<?=$len;?>"><?=$len;?></option> - <?php endforeach; ?> + <?php + endforeach; + if (!count($cert_keylens)) + echo "<option></option>"; + ?> </select> bits </td> |