コード例 #1
0
 /**
  * 管理评论
  */
 public function listarticlereply()
 {
     $articlereply = new ArticleReplyModel();
     // 当前页码
     $page = isset($_GET['page']) ? intval($_GET['page']) : 1;
     // 每页显示数量
     $counts = $GLOBALS['config']['admin_goods_pagecount'];
     //计算分页次数
     $pagecount = $articlereply->getAddNum();
     // 总记录数
     $pages = ceil($pagecount / $counts);
     // 字符过滤
     if (!is_integer($page) || $page < 1 || $page > $pages) {
         $page = 1;
     }
     // 分页显示数据
     $tables = $articlereply->getAllLogs($page, $counts);
     // 分页字符串
     $pagestr = Page::setAHtmlPage('index.php', 'index', 'listartice', $pagecount, $counts, $page);
     include_once VIEW_DIR . '/message_list2.html';
 }