for ($i = 0; $i < count($boards); $i++) { $selected = ""; if ($boardId == $boards[$i]['id']) { $selected = "selected=\"selected\""; } echo "<option value='{$boards[$i]['id']}' {$selected}>{$boards[$i]['name']}</option>"; } ?> </select> <br /> <table id="t01" border="0" style="width: 100%"> <?php $pro = new UtilA($result, $result); for ($i = 0; $i < count($result); $i++) { $style = $i % 2 == 0 ? "" : "background: #eee"; $savePath = $pro->path2url($result[$i]['savePath']); ?> <tr style="<?php echo $style; ?> "> <td><?php echo "<a href='{$savePath}' target='blank'><img width=60 height=60 src='{$pro->path2url($result[$i]['iconPath'])}' /></a>"; ?> </td> <td> <table border="0"> <tr> <td><?php echo "<a href='{$savePath}' target='blank'>" . $result[$i]['title'] . "</a>"; ?>