PHPackages                             lipichang/pagination - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. lipichang/pagination

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

lipichang/pagination
====================

分页，提供分页总数，分页参数自动分割，有默认样式可以参考也可以自己定义

038PHP

Since Jan 12Pushed 4y ago1 watchersCompare

[ Source](https://github.com/lipichang/page)[ Packagist](https://packagist.org/packages/lipichang/pagination)[ RSS](/packages/lipichang-pagination/feed)WikiDiscussions master Synced 4w ago

READMEChangelogDependenciesVersions (1)Used By (0)

pagination
==========

[](#pagination)

数组分页,可定制样式,内置3种样式,稍微修改一下可使用与所有的情形下的数组分页

Installation
------------

[](#installation)

Pagination is available on [Packagist](https://packagist.org/packages/lipichang/pagination).Just add this line to your `composer.json` file:

```
"lipichang/pagination": "dev-master"
```

or run

```
composer require lipichang/pagination:dev-master
```

### Example

[](#example)

```
use Lipichang\Pagination;
$pagination = new Pagination($totalPage,['style' => 1,'is_style' => true,'is_follow' => true,'simple'=>false,'allCounts'=>true,'nowAllPage'=>true,'toPage'=>true],['title' => 'shoes']);

//分页样式的渲染
$page = $pagination->render();
```

### Explanation

[](#explanation)

参数类型说明totalPageint总页数styleint分页样式，可选值1,2,3is\_styleboolean是否使用默认样式true是 false否 默认trueis\_followboolean是否允许搜索引擎跟踪 true 是 false 否 默认truesimplebooleantrue:简单的分页样式,false:复杂的分页样式allCountsboolean显示总页数nowAllPageboolean显示现在的页码toPageboolean跳转页码的功能queryarray分页其他查询参数### Show

[](#show)

#### simple模式

[](#simple模式)

[![simple模式](https://camo.githubusercontent.com/98d9885277f268b39e8bc337897a3b999756aca5f49f2d5a8ad800c1e09c87e5/68747470733a2f2f692e6c6f6c692e6e65742f323031392f30352f32322f3563653462343535626235656537393431382e706e67)](https://camo.githubusercontent.com/98d9885277f268b39e8bc337897a3b999756aca5f49f2d5a8ad800c1e09c87e5/68747470733a2f2f692e6c6f6c692e6e65742f323031392f30352f32322f3563653462343535626235656537393431382e706e67)

#### style = 1,2,3

[](#style--123)

[![Image1 text](https://camo.githubusercontent.com/d29fbe5584be9060d1e1ff7762487cb31decce28ffc64320917098035a2fd4e5/68747470733a2f2f692e6c6f6c692e6e65742f323031392f30352f32322f3563653462346437333462643938313630342e706e67)](https://camo.githubusercontent.com/d29fbe5584be9060d1e1ff7762487cb31decce28ffc64320917098035a2fd4e5/68747470733a2f2f692e6c6f6c692e6e65742f323031392f30352f32322f3563653462346437333462643938313630342e706e67)

[![Image1 text](https://camo.githubusercontent.com/c4806c11855cb0682d775bb0b3a082cb14a690e740ace49ed5a91a72228ea791/68747470733a2f2f696d672e6d79736f7572636966792e636f6d2f323032322f30312f31302f33313761323938356165666338623131373462396535313931386330653336352e706e67)](https://camo.githubusercontent.com/c4806c11855cb0682d775bb0b3a082cb14a690e740ace49ed5a91a72228ea791/68747470733a2f2f696d672e6d79736f7572636966792e636f6d2f323032322f30312f31302f33313761323938356165666338623131373462396535313931386330653336352e706e67)

[![Image1 text](https://camo.githubusercontent.com/848722da87184858d5ed481c109a7f3509f227ea7034f1a848dea2498553d0ee/68747470733a2f2f692e6c6f6c692e6e65742f323031392f30352f32322f3563653462353032336162373635343731302e706e67)](https://camo.githubusercontent.com/848722da87184858d5ed481c109a7f3509f227ea7034f1a848dea2498553d0ee/68747470733a2f2f692e6c6f6c692e6e65742f323031392f30352f32322f3563653462353032336162373635343731302e706e67)

#### allCount,nowAllPage,toPage模式

[](#allcountnowallpagetopage模式)

[![Image1 text](https://camo.githubusercontent.com/16bd96cf959e0da40fd60e79d47418f500e385159a36e3d9f687f6547bf68dcd/68747470733a2f2f692e6c6f6c692e6e65742f323031392f30352f32322f3563653462353131393263323332353033302e706e67)](https://camo.githubusercontent.com/16bd96cf959e0da40fd60e79d47418f500e385159a36e3d9f687f6547bf68dcd/68747470733a2f2f692e6c6f6c692e6e65742f323031392f30352f32322f3563653462353131393263323332353033302e706e67)

###  Health Score

16

—

LowBetter than 5% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity27

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/aae9de22c43fce7e69d05a61cdf02eacca0f6787f0e9ac0aa415510b17f68065?d=identicon)[lipichang](/maintainers/lipichang)

---

Top Contributors

[![lipichang](https://avatars.githubusercontent.com/u/5976690?v=4)](https://github.com/lipichang "lipichang (22 commits)")

### Embed Badge

![Health badge](/badges/lipichang-pagination/health.svg)

```
[![Health](https://phpackages.com/badges/lipichang-pagination/health.svg)](https://phpackages.com/packages/lipichang-pagination)
```

###  Alternatives

[shipmonk/name-collision-detector

Simple tool to find ambiguous classes or any other name duplicates within your project.

362.1M34](/packages/shipmonk-name-collision-detector)[bostondv/bootstrap-ninja-forms

Adds Bootstrap classes to Ninja Forms

222.2k](/packages/bostondv-bootstrap-ninja-forms)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
