我想在一行显示三列,显示完后,在另起一行显示直到数据库里没有记录了为止,
问如下这段代码怎么修改才能实现此功能呢?先谢啦!:-)
<table width="100%" border="0" cellspacing="5" cellpadding="0">
<% set rs=server.CreateObject("adodb.recordset")
sql="select * from consume_class2 where class2_class1id=1 "
rs.open sql,conn,1,1
do while not rs.eof %>
<tr valign="middle">
<% for i=1 to 3 %>
<td height="18" bgcolor="#F2f2f2"><div align="center"><a href="hqbj.htm" target="_blank"><%response.Write( rs("class2_name"))%></a></div></td>
<% rs.movenext
next %>
</tr>
<% loop %>
</table>