求救,ASP怎么做翻页,我的翻页老是做不成功,求大家帮忙看看,附代码。

[复制链接]
查看11 | 回复2 | 2010-5-21 10:53:03 | 显示全部楼层 |阅读模式
具体如下,帮忙看看吧!!


幸福之家
"" then
currentpage=clng(request("page"))
if currentpage>rs.pagecount then
currentpage=rs.pagecount
end if
else
currentpage=1
end if
totalnews=rs.recordcount
if currentpage1 then
if (currentpage-1)*newsperpage

  • [url=]"target=_blank>[/url]---


    当前没有内容!


    /页,共有篇文章/每页篇。
    |10 then
    showye=10
    end if
    for i=1 to showye
    if i=currentpage then
    %>

    [url=]">[/url]
    currentpage then
    if request("page")="" then
    page=1
    else
    page=request("page")+1
    end if%>
    [url=]" title="下一页">|[/url]






  • 回复

    使用道具 举报

    千问 | 2010-5-21 10:53:03 | 显示全部楼层
    一些相关定义自己写,比如dim i等function PageBarNum(total,perpage,current,filename) dim sRet,pageListCount,i,className pageListCount=10 If total mod perPage=0 Thentotal=total/perPage Elsetotal=Int(total/perpage)+1 ENd If 'Response.Write(total) 'Response.End() if total>0 thendim startNumstartNum=Int((current
    回复

    使用道具 举报

    千问 | 2010-5-21 10:53:03 | 显示全部楼层
    给你断分页代码吧 把和数据库有关的东西一改就哦了 还有就是下面分页连接(news.asp)改成你的文件名 [table][tr]
    [td]幸福之家<table
    回复

    使用道具 举报

    您需要登录后才可以回帖 登录 | 立即注册

    本版积分规则

    主题

    0

    回帖

    4882万

    积分

    论坛元老

    Rank: 8Rank: 8

    积分
    48824836
    热门排行