Skip to content

Commit

Permalink
Update pagelist.php
Browse files Browse the repository at this point in the history
  • Loading branch information
Kation committed May 31, 2013
1 parent 43121d4 commit 28a926e
Showing 1 changed file with 18 additions and 2 deletions.
20 changes: 18 additions & 2 deletions public/pagelist.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
<a href="/" class="back-button big page-back"></a>
</div>
</div>

<div class="page-region">
<div class="page-region-content">
<div id="pageContent">This is the page of 1</div>
Expand All @@ -17,11 +16,28 @@
var page = $("#pageDiv").pagelist();
page.total = 10;
page.current = 1;
page.url = "pagelistResult.php?page={page}";
page.url = "pagelistresult.php?page={page}";
page.ajax = "#pageContent";
page.create();
});
</script>
<h2>Component usage</h2>
<pre class="prettyprint linenums span10">
var page = $("#page").pagelist();
page.total = 10; //Total pages
page.current = 1; //Current page
page.showcount = 2; //Default is 2
page.url = "pagelistresult.php?page={page}"; //Jump url
page.ajax = "#contnet"; //if you want to use ajax, set value to target element, defaul is null
//If you want to use your own template
//page.pageTemplate = '...';
//page.pageSideTemplate = '...';
//page.pageItemTemplate = '...';
//page.pageCurrentTemplate = '...';
//page.pageMoreTemplate = '...';
//page.pageJumpTemplate = '...';
page.create(); //Create page list
</pre>
</div>
</div>
</div>
Expand Down

0 comments on commit 28a926e

Please sign in to comment.