Developer Network Home - Help

YUI Library Examples: DataTable Control: Configuring the Paginator

DataTable Control: Configuring the Paginator

This example demonstrates the various configuration options for the YAHOO.widget.Paginator class. Note that all navigation in the left column is generated by the Paginator.

Customizing pagination

Besides the normal configurations for pagination, we'll demonstrate the use of the other Paginator configuration options. Most notably, we'll use the template and pageLabelBuilder options to render the pagination controls in a custom layout with more descriptive page links.




We'll start by making sure our data is in order, then define the function that we'll use to populate the page links.

We'll assign something to every available Paginator configuration key, if even the default value, just for illustration.

Beyond this, it's simply a matter of creating your DataTable as normal.

Copyright © 2017 Yahoo! Inc. All rights reserved.

Privacy Policy - Copyright Policy - Job Openings