例如这个网址www.shangye168.com/get.asp?name=sql 我想从数据库中查询当这个地址栏中的参数name与数据库中的name字段值相等时再页面中显示 sex age time
代码应该怎么写呢...请教各位,帮帮忙啊...
[此贴子已经被作者于2007-7-12 11:25:41编辑过]
name=request.QueryString("name")
set rs=Server.CreateObject("ADODB.RecordSet")
rs.open"select * from 数据表 order by 字段 ",conn,1,1
while not rs.eof
if rs("name")=name then
response.write rs("name")
response.write rs("age")
response.write rs("sex")
response.write rs("time")
end if
rs.movenext()
wend
name=request.QueryString("name")
set rs=Server.CreateObject("ADODB.RecordSet")
rs.open"select * from 数据表 order by 字段 ",conn,1,1
while not rs.eof
if rs("name")=name then
response.write rs("name")
response.write rs("age")
response.write rs("sex")
response.write rs("time")
end if
rs.movenext()
wend