發(fā)表日期:2018-09 文章編輯:小燈 瀏覽次數(shù):1362
$dsql->SetQuery("SELECT evalue,ename from `ddmx_sys_enum` where egroup='center' AND evalue%500 = 0 order by disorder asc, evalue asc");$dsql->Execute(); $enums = array();$sort = 1 ;while($row = $dsql->GetArray()){$options .= "<option value=\"{$sort}\">{$row['ename']}</option>\r\n";$enums[] = $row['evalue'];$sort ++ ;}$count = count($enums);foreach($enums as $i=>$evalue){ |
$dsql->SetQuery("SELECT evalue,ename,link from `ddmx_sys_enum` where egroup='center' AND evalue > {$evalue} AND evalue < ({$evalue} + 500) order by disorder asc, evalue asc");$dsql->Execute();$sort = 0 ;$i++;while($row = $dsql->GetArray()){$js .= "select2[". $i ."][{$sort}] = new Option(\"{$row['ename']}\", \"{$row['link']}\");\r\n";$sort++;}} $html = '<form name="frm"><div class="city_sch"><h2 class="f13">選擇里您最近的學(xué)習(xí)中心</h2><table width="190" height="128" border="0" align="center" cellpadding="0" cellspacing="0"><tr><td height="51" align="center" valign="middle"><label><select name="s1" onChange="redirec(document.frm.s1.options.selectedIndex)"><option selected>點擊選擇城市</option>'. $options .'</select></label></td></tr><tr><td height="22" align="center" valign="middle"><label><select name="s2" id="s2"> <option value="點擊選擇中心" selected>點擊選擇中心</option></select></label></td></tr><tr><td height="55" align="center" valign="middle"><label><input type="submit" name="button" id="button" value="馬上提交" onclick="window.location=document.frm.s2.value;return false;"/></label></td></tr></table></div></form><script language="javascript">var select1_len = document.frm.s1.options.length;var select2 = new Array(select1_len);for (i=0; i<select1_len; i++){select2[i] = new Array();}select2[0][0] = new Option("請選擇", " ");'. $js .'function redirec(x){var temp = document.frm.s2; for (i=0;i<select2[x].length;i++){temp.options[i]=new Option(select2[x][i].text,select2[x][i].value);}temp.options[0].selected=true;}</script>'; $html = addslashes(str_replace(array("\r\n", '"'), array('', '\''), $html));echo "document.write(\" $html \")";?> |
日期:2018-09 瀏覽次數(shù):4421
日期:2018-09 瀏覽次數(shù):3063
日期:2018-09 瀏覽次數(shù):3898
日期:2018-09 瀏覽次數(shù):3828
日期:2018-09 瀏覽次數(shù):3391
日期:2018-09 瀏覽次數(shù):3780
日期:2018-09 瀏覽次數(shù):3228
日期:2018-09 瀏覽次數(shù):3492
日期:2018-09 瀏覽次數(shù):3238
日期:2018-09 瀏覽次數(shù):3269
日期:2018-09 瀏覽次數(shù):3002
日期:2018-09 瀏覽次數(shù):3554
日期:2018-09 瀏覽次數(shù):3530
日期:2018-09 瀏覽次數(shù):3103
日期:2018-09 瀏覽次數(shù):3026
日期:2018-09 瀏覽次數(shù):3796
日期:2018-08 瀏覽次數(shù):2994
日期:2018-08 瀏覽次數(shù):3157
日期:2018-08 瀏覽次數(shù):2973
日期:2018-08 瀏覽次數(shù):2977
日期:2018-08 瀏覽次數(shù):3020
日期:2018-08 瀏覽次數(shù):2784
日期:2018-08 瀏覽次數(shù):2905
日期:2018-08 瀏覽次數(shù):2850
日期:2018-08 瀏覽次數(shù):2867
日期:2018-08 瀏覽次數(shù):3031
日期:2018-08 瀏覽次數(shù):3091
日期:2018-08 瀏覽次數(shù):3413
日期:2018-08 瀏覽次數(shù):2938
日期:2018-08 瀏覽次數(shù):3250
Copyright ? 2013-2018 Tadeng NetWork Technology Co., LTD. All Rights Reserved.