分页程序可以显示,但不起一点作用,请赐教!!
分页代码:
<!--#include file="config.asp"-->
<%
If session("login")=false then
response.redirect"index.htm"
End If
str="Provider=Microsoft.Jet.OLEDB.4.0;Data Source="&Server.Mappath("phone.mdb")
Set conn=Server.CreateObject("ADODB.Connection")
conn.Open str
Set rs=Server.CreateObject("ADODB.Recordset")
rs.pagesize=3
sql="select * from tzf"
rs.Open sql,conn,1,1
snum=cint(request("s"))
maxpage=rs.pagecount
snum=rs.absolutepage
If snum="" OR snum<0 then
snum=1
End If
If snum=>maxpage then
snum=maxpage
End If
%>
<htm>
<body>
<center>
<table width=300 border=0>
<%
for i=0 to rs.pagesize and not rs.bof
%>
<tr>
<td width=50 style="border:1pt dotted #88E8F8"><font color=gray size=2pt face=宋体>姓名</font></td>
<td width=200 style="border:1pt dotted #88E8F8"><font color=gray size=2 face=宋体><%=rs("name")%></font></td>
<td width=50 style="border:1pt dotted #88E8F8"><a href="del.asp?id=<%=rs("id")%>"><font color=gray size=2pt face=宋体>删除</font</a></td>
</tr>
<tr>
<td width=50 style="border:1pt dotted #88E8F8"><font color=gray size=2pt face=宋体>内容</font></td>
<td style="border:1pt dotted #88E8F8"><font color=gray size=2 face=宋体><%=rs("tel")%></font></td>
<td style="border:1pt dotted #88E8f8"> </td>
</tr>
<tr>
<td width=50 style="border:1pt dotted #88E8F8"><font color=gray size=2pt face=宋体>类别</font></td>
<td style="border:1pt dotted #88E8F8"><font color=gray size=2 face=宋体><%=rs("zjt")%></font></td>
<td style="border:1pt dotted #88E8f8"> </td>
</tr>
<tr>
<td width=50 style="border:1pt dotted #88E8F8"><font color=gray size=2pt face=宋体>id</font></td>
<td style="border:1pt dotted #88E8F8"><font color=gray size=2 face=宋体><%=rs("id")%></font></td>
<td style="border:1pt dotted #88E8f8"> </td>
</tr>
<tr>
<td>
<table>
<tr>
<td>
</td>
</tr>
<tr>
<td>
</td>
</tr>
</table>
</td>
</tr>
<%
rs.movenext
if rs.eof then exit for
next
%>
</table>
<table>
<tr>
<td style="border:1pt dotted #88e8f8"><font color=gray face=宋体 size=2 >共有<%=maxpage%>页</font>
<% for i=1 to rs.pagecount
Response.Write "<a href=find.asp?s="&i&">"&i&"</a> "
next%>
</td>
</tr>
</table>
</center>
</body>
</htm>
其他文件再附件help.rar里!!!
谢谢!!!此次问题只针对分页无效问题,谢谢!!!
[此贴子已经被作者于2006-2-23 17:33:11编辑过]