Skip to content

gokhankurtulus/php-pagination

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

php-pagination

Simple pagination (Pure PHP)

PHP version

Used Faker for test function with fake datas. Remove related lines if you don't want to use Faker.

This project can help you to manage pages and listing items. It won't get items from Database or something else, you need to get those values and pass it to the function.

paginate function returns the list of pages you need.

Check values before pass the function to prevent fatal errors.

Try to keep $maxPaginationItems in odd numbers to center items properly.

Simple usage

use Pagination\Pagination;
echo Pagination::paginate($currentIndex, $itemsPerPage, $totalItems, $maxPaginationItems, $link);

About

Simple pagination (Pure PHP)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages