diff options
author | N0YB <Al_Stu@Frontier.com> | 2014-06-21 14:16:05 -0700 |
---|---|---|
committer | N0YB <Al_Stu@Frontier.com> | 2014-06-21 14:16:05 -0700 |
commit | 60a5f9de37aac2f2f54bb04590b7941c68c30e3b (patch) | |
tree | 25bd930fe42bcf047a074428ca5f99e12bddf939 /usr/local/www/system_advanced_admin.php | |
parent | 2464e353414a60a867cba82837e34d4e37e0b075 (diff) | |
download | pfsense-60a5f9de37aac2f2f54bb04590b7941c68c30e3b.zip pfsense-60a5f9de37aac2f2f54bb04590b7941c68c30e3b.tar.gz |
Use count($array) where applicable, instead of a $rowIndex increment.
Diffstat (limited to 'usr/local/www/system_advanced_admin.php')
-rw-r--r-- | usr/local/www/system_advanced_admin.php | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/usr/local/www/system_advanced_admin.php b/usr/local/www/system_advanced_admin.php index 39c0423..919ad4b 100644 --- a/usr/local/www/system_advanced_admin.php +++ b/usr/local/www/system_advanced_admin.php @@ -355,16 +355,14 @@ function prot_change() { <td width="78%" class="vtable"> <select name="ssl-certref" id="ssl-certref" class="formselect"> <?php - $rowIndex = 0; foreach($a_cert as $cert): - $selected = ""; if ($pconfig['ssl-certref'] == $cert['refid']) $selected = "selected=\"selected\""; - $rowIndex++; ?> <option value="<?=$cert['refid'];?>" <?=$selected;?>><?=$cert['descr'];?></option> - <?php endforeach; - if ($rowIndex == 0) + <?php + endforeach; + if (!count($a_cert)) echo "<option></option>"; ?> </select> |