关于ASP循环显示的问题!!大家帮我解决一下

来源:百度知道 编辑:UC知道 时间:2024/05/13 11:22:15
sub home_news_img()
set rs = conn.execute("select top 2 tp,bt,html from news where lbid in(1,2,3,4,5,6) and zt=1 and lx=1 order by id desc")
do while not rs.eof
Response.Write "<table width=100% border=0 cellspacing=0 cellpadding=3><tr><td align=center valign=middle height=85>"&_
"<a href=html/"&rs("html")&" target=_blank><img src="&rs("tp")&" width=120 height=75 border=0></a>"&_
"</td></tr></table><table width=95% border=0 cellspacing=0 cellpadding=0 align='center' style='TABLE-LAYOUT: fixed'><tr><td

height=21 align='center' style='LEFT: 0px; WIDTH: 100%; WORD-WRAP: break-word'>"&_
"<a href=html/"&rs("html")&" target=_blank>"&rs("bt")&"</a>"&_
"</TD></TR></TABLE>"

sub home_news_img()
set rs = conn.execute("select top 2 tp,bt,html from news where lbid in(1,2,3,4,5,6) and zt=1 and lx=1 order by id desc")
i=0
Response.Write "<table width=100% border=0 cellspacing=0 cellpadding=0>"
Response.Write "<tr>"
Response.Write "<td width=25%>"
do while not rs.eof
Response.Write "<table width=100% border=0 cellspacing=0 cellpadding=3><tr><td align=center valign=middle height=85>"&_
"<a href=html/"&rs("html")&" target=_blank><img src="&rs("tp")&" width=120 height=75 border=0></a>"&_
"</td></tr></table><table width=95% border=0 cellspacing=0 cellpadding=0 align='center' style='TABLE-LAYOUT: fixed'><tr><td

height=21 align='center' style='LEFT: 0px; WIDTH: 100%; WORD-WRAP: break-word