Joomla! provides us with the JPagination class to help us
handle pagination in our extensions.
There are four important attributes associated with the JPagination class:
limitstart: This is the item at which we begin a page, for example the first
page will always begin with item 0.
limit: This is the maximum number of items to display on a page.
total: This is the total number of items across all the pages.
_viewall: This is the option to ignore pagination and display all items.
Before we head into piles of code, let's take the time to examine the listFooter, the
footer that is used at the bottom of pagination lists:
The box to the far left describes the maximum number of items to display per page
(limit). The remaining buttons are used to navigate between pages. The final text
defines the current page out of the total number of pages.
The great thing about this footer is we don't have to work very hard to create it!
We can use a JPagination object to build it. This not only means that it is easy to
implement, but that the pagination footers are consistent throughout Joomla!.
Pages:
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311