How to Use the smartpaginator paging plug-in

Source: Internet
Author: User

Recently I intentionally studied the http://www.it28.cn using jquery's smartpaginator paging plug-in,

I would like to share with you

1. Introduce CSS and JS packages
<LINK rel = "stylesheet" href = "/CSS/smartpaginator.css"/>

<SCRIPT type = "text/JavaScript" src = "/scripts/smartpaginator. js"> </SCRIPT>

 

Finally, configure the paging parameters.
<SCRIPT type = "text/JavaScript">

$ (Document). Ready (function (){

$ ('. Pagination'). smartpaginator ({

Totalrecords: 33641,

Recordsperpage: 35,

Length: 15,

Next: 'Next page ',

PREV: 'preput ',

First: 'First page ',

Last: 'End page ',

Go: 'Go ',

Theme: 'red ',

Controlsalways: True,

Onchange: function (pageindex ){

Alert ("This part loads your paging content ")
},

Error: function (){

$ ("# Loadtbl" ).empty().html ("<tr> <TD colspan = '3' class = 'loadtext'> loading times out. Please refresh... </TD> </tr> ");

Return false;

}

});

}

});

});

</SCRIPT>

 

In this way, Ajax paging is used to load content.

Note:CodeCollected on www.it28.cnYou can download the CSS and JS packages on this website.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.