ASP 翻页代码问题

来源:百度知道 编辑:UC知道 时间:2024/05/15 23:31:40
看起来正常。。。地址有翻页。但内容却没有变
<%
Const MaxPerPage=10
dim totalPut
dim CurrentPage
dim TotalPages
dim j
dim sql
if Not isempty(SafeRequest("page",1)) then
currentPage=Cint(SafeRequest("page",1))
else
currentPage=1
end if
set rs=server.CreateObject("adodb.recordset")
rs.open "select id,title,date from log order by date desc",conn,1,1
if rs.eof And rs.bof then
Response.Write "<p align='center'> 对不起,目前还没有日志!</p>"
else
totalPut=rs.recordcount
if currentpage<1 then
currentpage=1
end if
if (currentpage-1)*MaxPerPage>totalput then
if (totalPut mod MaxPerPage)=0 then
currentpage= totalPut \ MaxPerPage
else
currentpage= totalPut \ MaxPerPage + 1
end if
end if
if currentPage=1 then
showContent
showpage totalput,MaxPerPage,"log.asp"
else

有几个代码错啦。
重下载一个哇
http://lcwork.cn/article.asp

少了语句
在你获得好页数之后加上rs.absolutepage=page(这里得page是你要转到的页数)

你的指针呢??