注:文章内容来源于网络,真实性有待确认,请自行甄别。
asp关于页面变量传递的问题,急,高分<%ic=Reque
发表于:2024-10-24 00:00:00浏览:3次
问题描述:<%
ic=Request.QueryString("ic")
set rs=server.createobject("adodb.recordset")
sql="select * f sa where ic = "&ic
rs.open sql,conn,1,1
if not rs.eof then
else
response.write "此内容不存在!"
response.end
end if
%>
在页面的能用<%=ic%>接收传递过来的变量,但用<%=r<%
ic=Request.QueryString("ic")
set rs=server.createobject("adodb.recordset")
sql="select * f sa where ic = "&ic
rs.open sql,conn,1,1
if not rs.eof then
else
response.write "此内容不存在!"
response.end
end if
%>
在页面的能用<%=ic%>接收传递过来的变量,但用<%=rs("")%>显示sa 表里的数据时却显示不出来,如果嫌分低我再加.
穿过来的IC 是数字还是字符串?
字符串的话要加 ''
sql="select * from sa where ic = '"& ic &"'"
栏目分类全部>