Ajax paging tutorial for jQueryPagination (jquery. pagination. jsv1.2 download)

Source: Internet
Author: User
The Ajax paging user experience is certainly better. jQueryPagination is easy to implement Ajax paging. I use jquery. pagination. jsv1.2. The parameters are described as follows: & amp; nbsp; jQueryPagi

The Ajax paging user experience is certainly better. jQuery Pagination is easy to implement Ajax paging. I use jquery. pagination. js v1.2. The parameters are described as follows:

The jQuery Pagination Ajax paging tutorial is as follows:

/** By http://www.phpddt.com */var items_per_page = 20; var page_index = 0; function getDataList (index) {var pageIndex = index; $. ajax ({type: "POST", url: "/information/import/get_articles", data: "uid = {$ account_id} & token = {$ account_token} & page_index =" + pageIndex + '& items_per_page =' + items_per_page, ype: 'json', contentType: "application/x-www-form-urlencoded", success: function (msg) {$ (". article_box_table "). remove (); var html = ''; $. each (msg. result, function (I, da) {html + ='
 
 
  • '+ Da. title +'
  • '+ For_php_date_to_str (da. posttime) +'
';}); $ (". Article_box_top "). after (html) ;}});} function pageselectCallback (page_index, jq) {getDataList (page_index);} getDataList (page_index); $ ("# page "). pagination ("{$ count}", {'items _ per_page ': items_per_page, 'num _ display_entries': 10, 'num _ edge_entries ': 1, 'prev _ text ': "Previous page", 'next _ text': "next page", 'callback': pageselectCallback, 'current _ page': page_index ,});

The effect is as follows:


Related Article

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.