PHPackages                             agelxnash/seopagination - 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. agelxnash/seopagination

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

agelxnash/seopagination
=======================

Laravel SEO Pagination

5.2.2(9y ago)61.0k2MITPHPPHP &gt;=5.4.0

Since Aug 19Pushed 9y ago1 watchersCompare

[ Source](https://github.com/AgelxNash/SEOPagination)[ Packagist](https://packagist.org/packages/agelxnash/seopagination)[ RSS](/packages/agelxnash-seopagination/feed)WikiDiscussions laravel-5.1 Synced 1mo ago

READMEChangelogDependencies (1)Versions (20)Used By (0)

Laravel SEO Pagination
======================

[](#laravel-seo-pagination)

This extension pack pagination laravel. With it, you can prevent the opening of blank pages. For example, in your pagination has only 10 pages, but the user has requested page with number 101. With this extension pack, user redirected to the last (10) or first page... or send 404 error.

And most importantly, paginator now contains no reference to the first page with the GET variable.

### Old

[](#old)

```
http://example.com/news?page=1
http://example.com/news?page=2
http://example.com/news?page=3
...
etc.

```

### New

[](#new)

```
http://example.com/news
http://example.com/news?page=2
http://example.com/news?page=3
...
etc.

```

Installation
============

[](#installation)

### Step 1

[](#step-1)

```
composer require agelxnash/seopagination:5.2.*@dev

```

### Step 2

[](#step-2)

Once SEOPagination is installed you need to register the service provider with the application. Open up `config/app.php` and replace `Illuminate\Pagination\PaginationServiceProvider` the providers key to

```
AgelxNash\SEOPagination\PaginationServiceProvider::class

```

Configuration
=============

[](#configuration)

You will want to run the following command to publish the config to your application, otherwise it will be overwritten when the package is updated.

```
php artisan vendor:publish --provider="AgelxNash\SEOPagination\PaginationServiceProvider"
```

Now you can edit the file `config/seo-pagination.php`

### action\_on\_error

[](#action_on_error)

- **first** (*Send redirect to first pagination page with error\_status response status code*)
- **out** (*Send redirect to end pagination page with error\_status response status code*)
- **abort** (*Return 404 error. Not use error\_status*)

### error\_status

[](#error_status)

**Any response status code**. For example - 307 (*default*) or 301

Usage
=====

[](#usage)

Add the trait to your model

```
use Illuminate\Database\Eloquent\Model;

Class Post extends Model{
	use \AgelxNash\SEOPagination\Eloquent\ReplaceBuilder
}
```

After the call paginate() method, you can check data variable in the method `checkPaginate()`. The result will be object `\Illuminate\Http\RedirectResponse` or `true`Look at the example method of a controller with check pagination:

```
public function example()
{
	$posts = Post::->orderBy('created_at', 'DESC')->paginate(10);
	if(($out = $posts->checkPaginate()) === true){
		$out = View::make('index', array('data'=> $posts));
	}
	return $out;
}
```

###  Health Score

34

—

LowBetter than 77% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity22

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor1

Top contributor holds 85.3% 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.

###  Release Activity

Cadence

Every ~48 days

Recently: every ~77 days

Total

14

Last Release

3296d ago

Major Versions

4.0.0 → 5.1.02015-08-19

PHP version history (2 changes)4.2.0PHP &gt;=5.3.0

5.1.0PHP &gt;=5.4.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/cd6eeb152aa8a6a81b05883f09f583f4fafbc50935495d79a2d8a01e0e5f9aa6?d=identicon)[Agel Nash](/maintainers/Agel%20Nash)

---

Top Contributors

[![AgelxNash](https://avatars.githubusercontent.com/u/1748872?v=4)](https://github.com/AgelxNash "AgelxNash (29 commits)")[![daguilarm](https://avatars.githubusercontent.com/u/2663941?v=4)](https://github.com/daguilarm "daguilarm (3 commits)")[![Gael42](https://avatars.githubusercontent.com/u/5319819?v=4)](https://github.com/Gael42 "Gael42 (2 commits)")

---

Tags

laravelpagepaginatorpaginationlistseo

### Embed Badge

![Health badge](/badges/agelxnash-seopagination/health.svg)

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

###  Alternatives

[beberlei/porpaginas

Library that generically solves several pagination issues with DAO/repository abstractions.

163612.6k11](/packages/beberlei-porpaginas)[lampager/lampager-laravel

Rapid pagination for Laravel

7641.4k](/packages/lampager-lampager-laravel)[usmanhalalit/strana

Pagination library for PHP, framework agnostic, with built-in adapters for Doctrine, Eloquent, Pixie and PHP Array.

947.4k3](/packages/usmanhalalit-strana)[voodoophp/paginator

Paginator is a simple class that allows you to create pagination. It doesn't require any database connection. It is compatible with Twitter's Bootstrap Framework, by using the CSS class pagination that is also attached.

351.5k1](/packages/voodoophp-paginator)

PHPackages © 2026

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