jQuery 分页插件 jqPagination

码农软件 · 软件分类 · jQuery分页插件 · 2019-12-13 17:59:25

软件介绍

jqPagination 是一个简单易用的轻量级 jQuery 分页插件,其使用了 HTML5 和 CSS3 技术来实现。此插件提供了几个参数设置选项,通过简单的配置即可生成分页控件。此外,它的外观样式是可自定义的,扩展性很强。

使用方法:

添加 jQuery 类库、jqPagination 插件的 JS 和 CSS 文件

<link rel="stylesheet" target="_blank" rel="nofollow" href="jqpagination.css"/>
<script src="jquery-1.6.2.min.js"></script>
<script src="jquery.jqpagination.min.js"></script>

再需要如下HTML

<div class="pagination">
  <a target="_blank" rel="nofollow" href="#" class="first" data-action="first">&laquo;</a>
  <a target="_blank" rel="nofollow" href="#" class="previous" data-action="previous">&lsaquo;</a>
  <input type="text" readonly="readonly" data-max-page="40" />
  <a target="_blank" rel="nofollow" href="#" class="next" data-action="next">&rsaquo;</a>
  <a target="_blank" rel="nofollow" href="#" class="last" data-action="last">&raquo;</a>
</div>

最后初始化插件

$('.pagination').jqPagination({
  link_string : '/?page={page_number}',
  current_page: 5, //设置当前页 默认为1
  max_page : 40, //设置最大页 默认为1
  page_string : '当前第{current_page}页,共{max_page}页',
  paged : function(page) {
      //回发事件。。。
      }
});

本文地址:https://www.codercto.com/soft/d/21076.html

Agile Web Development with Rails 4

Agile Web Development with Rails 4

Sam Ruby、Dave Thomas、David Heinemeier Hansson / Pragmatic Bookshelf / 2013-10-11 / USD 43.95

Ruby on Rails helps you produce high-quality, beautiful-looking web applications quickly. You concentrate on creating the application, and Rails takes care of the details. Tens of thousands of deve......一起来看看 《Agile Web Development with Rails 4》 这本书的介绍吧!

HTML 压缩/解压工具
HTML 压缩/解压工具

在线压缩/解压 HTML 代码

在线进制转换器
在线进制转换器

各进制数互转换器

RGB CMYK 转换工具
RGB CMYK 转换工具

RGB CMYK 互转工具