PHP Classes

wepesi PHP Pagination Library: Generate pagination for listing of query results

Recommend this page to a friend!
     
  Info   Example   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not yet rated by the usersTotal: 47 All time: 10,757 This week: 80Up
Version License PHP version Categories
wepesi_pagination 1.0.0The PHP License5HTML, PHP 5, Databases
Description 

Author

This package can generate links for listing split into multiple pages.

It can take the name of a table to perform database queries using PDO.

The package can get the number of records in the table and may optionally match a condition clause.

It can return an array with the total number of listing pages, number of active pages, and the query results.

Picture of Boss Ibrahim Mussa
  Performance   Level  
Name: Boss Ibrahim Mussa <contact>
Classes: 13 packages by
Country: Congo Congo
Age: ???
All time rank: 28851 in Congo Congo
Week rank: 21 Up1 in Congo Congo Equal
Innovation award
Innovation award
Nominee: 5x

Example

<?php
$pages
=isset($_GET['pages'])?(is_numeric($_GET['pages'])?$_GET['pages']:1):1;
$response=$message->getMessage($pages);
$totalPages=(int)$response["totalPages"];
$activepages=(int)$response["activepages"];
$result=$response["result"];
$link="";
echo
"<br>";
for(
$i=1;$i<=$totalPages;$i++){
   
$link.="<a href=\"./?pages=$i\" style=\"padding:15px;margin:10px;background:#e3e3e3;\">$i</a>";
}
echo
$link;
var_dump($result);
?>


Details

WEPESI PAGINATION

this is just a simple php module to help manage pagination on your application. hope you enjoy.

DOCUMENTATION

this module will a next part to complete the wepesi ORM you can find here https://github.com/bim-g/Wepesi-ORM.


  Files folder image Files (17)  
File Role Description
Files folder imageclass (4 directories)
Files folder imageinit (3 files)
Files folder imagesql (1 file)
Files folder imagetest (2 files)
Accessible without login Plain text file index.php Aux. Auxiliary script
Accessible without login Plain text file LICENSE Lic. License text
Accessible without login Plain text file README.md Doc. Documentation

  Files folder image Files (17)  /  class  
File Role Description
Files folder imageapp (1 file)
Files folder imageconfig (1 file)
Files folder imageDB (4 files)
Files folder imagepagination (2 files)

  Files folder image Files (17)  /  class  /  app  
File Role Description
  Plain text file Message.php Class Class source

  Files folder image Files (17)  /  class  /  config  
File Role Description
  Plain text file Config.php Class Class source

  Files folder image Files (17)  /  class  /  DB  
File Role Description
  Plain text file DB.php Class Class source
  Plain text file DB_Exec_Qeury.php Class Class source
  Plain text file DB_Query.php Class Class source
  Plain text file DB_Select.php Class Class source

  Files folder image Files (17)  /  class  /  pagination  
File Role Description
  Plain text file Pagination.php Class Class source
  Plain text file Pagination_Operation.php Class Class source

  Files folder image Files (17)  /  init  
File Role Description
  Accessible without login Plain text file config.ini Data Auxiliary data
  Accessible without login Plain text file global.php Example Example script
  Accessible without login Plain text file init.php Aux. Auxiliary script

  Files folder image Files (17)  /  sql  
File Role Description
  Accessible without login Plain text file wepesi_db.sql Data Auxiliary data

  Files folder image Files (17)  /  test  
File Role Description
  Accessible without login Plain text file index.php Example Example script
  Accessible without login Plain text file select.php Example Example script

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 100%
Total:47
This week:0
All time:10,757
This week:80Up