PHP Classes

Dynamic Pagination in PHP with MySQL Example with PHP Pagination Bootstrap: Show pagination of MySQL results for Bootstrap

Recommend this page to a friend!
  Info   Example   Screenshots   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
StarStarStar 45%Total: 2,882 All time: 1,304 This week: 40Up
Version License PHP version Categories
pagination-bootstrap 1.0The PHP License5.0HTML, PHP 5, Databases
Description 

Author

This class can show pagination of MySQL results for Bootstrap.

It extends the MySQLi wrapper to retrieve result rows for a query to a given table to display on a given page of a paginated listing.

The class can return result rows, as well HTML for the pagination links for use with Bootstrap.

Picture of Md. Shahadat Hossain Khan Razon
  Performance   Level  
Name: Md. Shahadat Hossain ... <contact>
Classes: 14 packages by
Country: Bangladesh Bangladesh

Recommendations

Pagination for content
Divide content into pages

Example

$schools=$db->getRowsWithPaging(TBL_UNI_SCHOOLS.' as s, '.TBL_COMMON_SCHOOLS.' as cs', $_REQUEST['_pno'], $_SERVER['PHP_SELF'].'?uid='.$university['uni_id'], 's.uni_id='.$university['uni_id'].' and s.common_school_id=cs.common_school_id');
if(isset($schools) && $schools->isAnyDataAvailable()){
    $schldata=$schools->get();
    foreach($schldata as $schl){
        echo '<div>'.$schl['school_title'].'</div>';
    }
    # pagination here
    echo '<p>'.$schools.'</p>';
}


Screenshots (1)  
  • pagination.jpg
  Files folder image Files (3)  
File Role Description
Plain text file pagingwithmysqli.cls.php Class pagination class file
Accessible without login Plain text file eg.php Example Simple Example

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
Downloadpagination-bootstrap-2014-02-28.zip 31KB
Downloadpagination-bootstrap-2014-02-28.tar.gz 31KB
Install with ComposerInstall with Composer
Needed packages  
Class DownloadWhy it is needed Dependency
MySQLi Wrapper Download .zip .tar.gz extend Required
 Version Control Unique User Downloads Download Rankings  
 0%
Total:2,882
This week:0
All time:1,304
This week:40Up
 User Ratings  
 
 All time
Utility:68%StarStarStarStar
Consistency:56%StarStarStar
Documentation:-
Examples:56%StarStarStar
Tests:-
Videos:-
Overall:45%StarStarStar
Rank:3336