Discuz教程网

[插件制作] Discuz X二次开发分页的写法示例

[复制链接]
authicon dly 发表于 2012-3-15 21:21:59 | 显示全部楼层 |阅读模式
  1. $perpage = 10;
  2. $page = intval ( $_G ['gp_page'] ) ? intval ( $_G ['gp_page'] ) : 1;
  3. $start = ($page - 1) * $perpage;
  4. if ($start < 0)
  5. $start = 0;
  6. $count = DB::num_rows ( DB::query ( 'select * from '.DB::table('it577_foot') ) );
  7. ………………
  8. $multi=multi ( $count, $perpage, $page, "plugin.php?id=it577_foot:index&mod=history" );
复制代码

对应的插件地址:https://www.discuz.1314study.com/thread-74145-1-1.html



上一篇:Discuz 站长联盟超级群群规(20233619)
下一篇:免费插件便民电话,版本已经更新至v1.1,设置更灵活
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

1314学习网 ( 浙ICP备10214163号 )

GMT+8, 2025-5-2 03:40

Powered by Discuz! X3.4

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表