工作简报的写法:求助 asp的问题

来源:百度文库 编辑:高考问答 时间:2024/05/04 17:11:19
如果数据库中存在图片<%=rs("picture")%> 就以400*300显示出来,没有就拉倒。 这句话用ASP怎么表达 ? 谢谢

<%
if rs("picture")<>null
response.writr(rs("picture"))
end if
%>

<%if rs("picture")<>empty then%>
<img src="<%=rs("picture")%>" width=400 height=300>
<%else
response.write ("数据库中没有图片")
end if %>

最简单的方法
if rs(\"picture\")<>\"\" then response.writr(rs(\"picture\"))