国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁(yè) > 編程 > ASP > 正文

網(wǎng)上用的比較多的asp級(jí)聯(lián)菜單效果代碼

2024-05-04 11:00:51
字體:
來(lái)源:轉(zhuǎn)載
供稿:網(wǎng)友

復(fù)制代碼 代碼如下:
<!--#include file="conn.asp"--> 
<html> 
<head> 
<meta http-equiv="Content-Type" content="text/html; charset=gb2312"> 
<meta name="GENERATOR" content="Microsoft FrontPage 4.0"> 
<meta name="ProgId" content="FrontPage.Editor.Document"> 
<title>New Page 1</title> 
</head> 
<body> 
<% 
dim rs 
dim sql 
dim count 
set rs=server.createobject("adodb.recordset") 
sql = "select * from shiinfo order by id asc" 
rs.open sql,conn,1,1 
%> 

<SCRIPT language="JavaScript"> 
var onecount; 
onecount=0; 
subcat = new Array(); 
<% 
count = 0 
do while not rs.eof  
%> 
subcat[<%=count%>] = new Array("<%= trim(rs("shiname"))%>","<%= trim(rs("shengcode"))%>","<%= trim(rs("id"))%>"); 
<% 
count = count + 1 
rs.movenext 
loop 
rs.close 
%> 
onecount=<%=count%>; 
function changelocation(locationid) 

document.form1.cid.length = 0;  
var locationid=locationid; 
var i; 
for (i=0;i < onecount; i++) 

if (subcat[i][1] == locationid) 
{  
document.form1.cid.options[document.form1.cid.length] = new Option(subcat[i][0], subcat[i][2]); 
}  

}  

</SCRIPT> 
<SCRIPT language="javascript"> 
<!-- 
function CheckForm() 

document.form1.txtcontent.value=document.form1.doc_html.value; 
return true 

//--> 
</SCRIPT> 
<form name=form1 onsubmit="check()"> 
省份 <% 
sql = "select * from shenginfo" 
rs.open sql,conn,1,1 
if rs.eof and rs.bof then 
response.write "請(qǐng)先添加省份。" 
response.end 
else 
%> 
<Select name="sid" onChange="changelocation(document.form1.sid.options[document.form1.sid.selectedIndex].value)" ><%  
do while not rs.eof 
%><OPTION selected value="<%=trim(rs("id"))%>"><%=trim(rs("shengname"))%></OPTION> 
<% 
rs.movenext 
loop 
end if 
rs.close 
%> 
</Select>  

發(fā)表評(píng)論 共有條評(píng)論
用戶名: 密碼:
驗(yàn)證碼: 匿名發(fā)表
主站蜘蛛池模板: 威远县| 海伦市| 达拉特旗| 江都市| 安新县| 扶余县| 修水县| 湖州市| 大方县| 横峰县| 黄大仙区| 曲松县| 布拖县| 磐石市| 兴安县| 海安县| 镇巴县| 静乐县| 根河市| 克什克腾旗| 米易县| 景泰县| 逊克县| 章丘市| 东山县| 罗定市| 卓尼县| 金堂县| 大安市| 精河县| 勐海县| 宝丰县| 乌兰察布市| 左贡县| 栾城县| 铁岭市| 昭苏县| 金川县| 福鼎市| 龙游县| 新民市|