asp首页显示产品数量问题
<table width="100%" border="0" cellpadding="2" cellspacing="1" bgcolor="#ffb888" class="margintop"><tr>
<td height="24" background="images/box_bg.gif" class="leftbiaoti">最新产品</td>
</tr>
<tr>
<td align="center" valign="middle" bgcolor="#FFFFFF" class="youbiantiachong"><%
set newsproducts=server.createobject("adodb.recordset")
exec="select top "&config("synewsproducts")&" * from [products] "
newsproducts.open exec,conn,1,1
if newsproducts.eof and newsproducts.bof then
response.Write(" 暂无最新产品 !")
end if%>
<table width="115" border="0" cellpadding="0" cellspacing="0">
<tr>
<%
dim i
i=1
do while not newsproducts.eof and i<=6
%>
<td>
<table width="100%" border="0" cellpadding="5" cellspacing="1">
<tr>
<td><div align="center"><a href="Productsviwe.asp?id=<%=newsproducts("id")%>" class="img" title="<%=newsproducts("title")%>"><img src="<%=newsproducts("img")%>" width="120" height="90" /></a></div></td>
</tr>
<tr>
<td><div align="center"><a href="Productsviwe.asp?id=<%=newsproducts("id")%>" title="<%=newsproducts("title")%>"><%=InterceptString(newsproducts("title"),18)%></a></div></td>
</tr>
</table> </td>
<%
if i mod 6 =0 then
response.Write "<tr>"
end if
i=i+1
newsproducts.movenext
loop
newsproducts.close
set newsproducts=nothing
%>
</tr>
</table></td>
</tr>
</table>
do while not newsproducts.eof and i<=6
改为1显示1个产品,改为2显示2个产品,……改为6还是显示5个产品
最终显示的是5个产品,我想显示6个。
要怎么改呢?》