asp.net学习_分页的设计(8)
来源:未知 责任编辑:责任编辑 发表时间:2014-04-20 03:40 点击:次
103: function renderButton(recordCount, goPageIndex, EventHander, text) {
104: var $goto = $("<a title=\"第" + goPageIndex + "页\">" + text + "</a>\"");
105: $goto.click(function() {
106:
107: EventHander(recordCount, goPageIndex,pagerDefaults.PageSize);
108: });
109: return $goto;
110: }
111: var pagerDefaults = {
112: DefaultPageCount: 1,
113: DefaultPageIndex: 1,
114: PageSize:20,
115: ShowPageNumber: true //是否显示页码
116: };
117: })(jQuery);
前台页面显示:
1: <%@ Page Language="C#" MasterPageFile="~/InfoPage.master" AutoEventWireup="true"
2: CodeFile="MasterList.aspx.cs" Inherits="Master_MasterList" Title="大师风采" %>
3:
4: <asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
5: <link href="../css/other.css" rel="stylesheet" type="text/css" />
6:
7: <script src="../Admin/scripts/jquery-1.7.1.min.js" type="text/javascript"></script>
8:
9: <script src="../js/jquery-pager-1.0.js" type="text/javascript"></script>
10:
11: <link href="../css/pager.css" rel="stylesheet" type="text/css" />
12:
13: <script type="text/javascript">
14: $(document).ready(function() {
15: //加载PageSize和页码PageIndex
16: GetData(1,1);
17: });
相关新闻>>
最新推荐更多>>>
- 发表评论
-
- 最新评论 更多>>