jquery 分页插件
来源:互联网 发布:wpsh5是什么软件 编辑:程序博客网 时间:2024/05/01 08:13
工作需要个人封装了一个jquery的分页插件 效果比较一般凑合能用,基本上功能都实现了,jquery第一次用写得比较代码写得感觉质量不高
用法很简单
pageInitJson={ items_per_page:10,//默认一个多少条记录num_display_entries:11,defuault_page:5,//默认显示多少页length_page:7,//分页条一共多少格start_page:1, //默认的开始页current_page:1,//第一次加载是那一页num_edge_entries:0,link_to:"#",prev_text:"<",//上一页的标志next_text:">",//下一页的标志ellipse_text:"...",prev_show_always:true,next_show_always:true,renderer:"defaultRenderer",is_location:false, callback:function(){}/这个是必要的,分页后调用的servlet}//初始化 其他的可以根据需要个性初始 /* params pageInitJson :初始后的pageInitJson num:一共多少条记录*/createPage(pageInitJson,num);<div="#page_f">
时间匆忙,很多可灵活配置的东西写死了