标签:
<td ><select id="pri_sel_‘.$v[‘id‘].‘"> <option value="1">随机</option>‘; if($v[‘rid‘]){ $selete = ‘‘; foreach($prizelist as $key=>$val){ if($v[‘rid‘] == $val[‘id‘]){ $selete = ‘selected‘; }else{ $selete = ‘‘; } echo ‘ <option value="‘.$val[‘id‘].‘" ‘.$selete.‘ >‘.$val[‘pname‘].‘</option>‘; } }else{ foreach($prizelist as $key=>$val){ echo ‘<option value="‘.$val[‘id‘].‘">‘.$val[‘pname‘].‘</option>‘; } } echo ‘</select></td>
标签:
原文地址:http://www.cnblogs.com/finnlee/p/5109916.html