Skip to content

heropoo/pagination

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pagination

Pagination

使用方法

install via composer

composer require heropoo/pagination

示例

avatar

$user_total = 100;
$page_size = 10;
$page = new Page($user_total, $page_size);
//获取分页 offset 参数
$limit = $page->getLimit();   //等于 $page_size
$offset = $page->getOffset();
//输出的html
$html = $page->getHtml();
echo $html;