如何利用數(shù)據(jù)庫內容建立一個下拉式列表?
如何利用數(shù)據(jù)庫內容建立一個下拉式列表?
<% myDSN="DSN=xur;uid=xur;pwd=xur"
mySQL="select * from authors where AU_ID<100"
set conntemp=server.createobject("adodb.connection")
conntemp.open myDSN
set rstemp=conntemp.execute(mySQL)
if rstemp.eof then
response.write "噢,數(shù)據(jù)庫為空!"
response.write mySQL
conntemp.close
set conntemp=nothing
response.end
end if%>
<%do until rstemp.eof %>
<%
rstemp.movenext
loop
rstemp.close
set rstemp=nothing
conntemp.close
set conntemp=nothing
' 清空對象
%>
相關文章
如何用ASP建立Index Server查詢對象并為其參數(shù)賦值?
如何用ASP建立Index Server查詢對象并為其參數(shù)賦值?...2006-11-11如何根據(jù)用戶銀行帳戶余額的多少進行顯式的提交或終止?
如何根據(jù)用戶銀行帳戶余額的多少進行顯式的提交或終止?...2006-11-11如何編寫一個創(chuàng)建FTP站點的函數(shù)?
如何編寫一個創(chuàng)建FTP站點的函數(shù)?...2006-11-11