PHP code example of pollen-solutions / pagination
1. Go to this page and download the library: Download pollen-solutions/pagination library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
pollen-solutions / pagination example snippets
use Pollen\Pagination\PaginationManager;
use Pollen\Pagination\Paginator;
$pagination = new PaginationManager();
$paginator = new Paginator(
[
'per_page' => 20,
'total' => 60,
]
);
var_dump($paginator->toArray());
$pagination->setPaginator($paginator);
echo $pagination;
use Pollen\Pagination\PaginationManager;
add_action('wp', function () {
echo new PaginationManager();
exit;
});