More than 1000+ satisfied clients and counting, since 2010


Pagination Class in Joomla Module – Complete Howto Guide

Pagination Class in Joomla ModuleIn Joomla content management system you can use a custom pagination class in extensions. This blog post covers how you can achieve this and successfully add the pagination class in Joomla module. Follow the steps given below.

How to Add Pagination Class in Joomla Module?

Step 1: Get Total No. of items in Your database

ex: select count(*) from #__some_table where ….
Step 2: Import Joomla Pagination and Create Pagination Object

$pagination = new JPagination($total, $limitstart, $limit);

$total = total number of items that you count in step 1
$limit = total number of items you want to display on a page $limitstart = index of the first item in the page. For example if you have 20 items per page, 0 is start index for 1 page, 20 is start index for second and so on.
Step 3: Show Pagination on Your Page

 echo $pagination->getPagesLinks();
 echo $pagination->getPagesCounter();

Complete Resources on Pagination Class in Joomla Module

You can get all the information on pagination class in Joomla module in the following link:
Official Joomla Documentation Site –

Written by

The author didnt add any Information to his profile yet