帮我分页一下。。数据库一共有24条,第6条一页。。谢了。。
<%@ language="VBScript"%>
<%
dim conn,rs,sql
set conn=server.CreateObject("adodb.connection")
conn.open "driver={microsoft access driver (*.mdb)};dbq=" +server.MapPath("mdb/bbs_db.mdb")
%>
<%
sql ="select * from bbs order by rq2 desc"
set comm=conn.execute(sql)
if not comm.eof then
do while not comm.eof
%>
<table width="554" height="95" border="0" align="center" cellpadding="0" cellspacing="2">
<tr bgcolor="#EAF4EE">
<td width="71" height="25"><div align="right">昵称:</div></td>
<td width="241"><span class="style1"><%=comm.fields("xm")%></span></td>
<td width="67"><div align="right">留言时间:</div></td>
<td width="164"><%=comm.fields("rq1")%> <%=comm.fields("rq2")%></td>
</tr>
<tr bgcolor="#EAF4EE">
<td height="25"><div align="right">留言内容:</div></td>
<td colspan="3"><table width="463" height="30" border="0" cellpadding="0" cellspacing="0">
<tr>
<td><%=comm.fields("context")%></td>
</tr>
</table></td>
</tr>
<tr>
<td height="10"> </td>
<td></td>
<td> </td>
<td> </td>
</tr>
</table>
<%
comm.movenext
loop
else
Response.Write "<p align='center'>没有内容...</p>"
end if
%>