You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -50,7 +50,7 @@ This repository ported from [Rundiz Pagination](https://github.com/Rundiz/pagina
50
50
### Options
51
51
| Param | Type | Description |
52
52
| --- | --- | --- |
53
-
| options.base_url | <code>string</code> | The URL for use when generate page numbers with links (Required). Set the position where page numbers will be appears as URI segment or query string with `%PAGENUMBER%` placeholder.<br>Example 1: `http://domain.tld/my-category/page/%PAGENUMBER%` This URL use page number as URI segment.<br>Example 2: `http://domain.tld/my-category?page=%PAGENUMBER%` This URL use page number as query string.<br>Example 3: `http://domain.tld/my-category?filter=some_filter_values&search=foobar&page=%PAGENUMBER%` This URL use page number as query string with other query strings in it, seperate each query string with `&` not just `&`.<br>Example 4: `http://domain.tld/my-category?start=%PAGENUMBER%` This URL use page number as query string but use start as the name. You have to get the page number value and set its value to this class by call the "page_number_value" option. |
53
+
| options.base_url | <code>string</code> | The URL for use when generate page numbers with links (Required).<br> Set the position where page numbers will be appears as URI segment or query string with `%PAGENUMBER%` placeholder.<br>Example 1: `http://domain.tld/my-category/page/%PAGENUMBER%` This URL use page number as URI segment.<br>Example 2: `http://domain.tld/my-category?page=%PAGENUMBER%` This URL use page number as query string.<br>Example 3: `http://domain.tld/my-category?filter=some_filter_values&search=foobar&page=%PAGENUMBER%` This URL use page number as query string with other query strings in it, seperate each query string with `&` not just `&`.<br>Example 4: `http://domain.tld/my-category?start=%PAGENUMBER%` This URL use page number as query string but use start as the name.<br> You have to get the page number value and set its value to this class by call the "page_number_value" option. |
54
54
| options.page_number_value | <code>number</code> | The current page number value (Required). This class cannot detect current page number automatically because of dynamic styles of URL. So, you have to manually set its value to this option. |
55
55
| options.total_records | <code>number</code> | The total number of records (Required). This means "all" records by conditions with out the "LIMIT" or slices commands. |
56
56
| options.items_per_page | <code>number</code> | The number of items that will be displaying per page. Such as number of articles to display in each page. Default is 10. |
@@ -93,4 +93,4 @@ This repository ported from [Rundiz Pagination](https://github.com/Rundiz/pagina
93
93
| options.unavailable_after | <code>number</code> \| <code>false</code> | Number of pages to display after last unavailable page. Set number as integer or set to false to not display the pages after unavailable. Default is 2. |
94
94
| options.unavailable_before | <code>number</code> \| <code>false</code> | Number of pages to display before first unavailable page. Set number as integer or set to false to not display the pages before unavailable. Default is 2. |
95
95
| options.events | <code>object</code> | The events to be called. |
96
-
| options.events.onclick | <code>function</code> | On click event. This event is fired after displayed pagination. Set callback function here to call when user clicked. If you set callback function, this class will not use `preventDefault()` to let you handle it. |
96
+
| options.events.onclick | <code>function</code> | On click event. This event is fired after displayed pagination. Set callback function here to call when user clicked. If you set callback function, this class will not use `preventDefault()` to let you handle it. |
Copy file name to clipboardExpand all lines: assets/js/rd-pagination.js
+6-6Lines changed: 6 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -58,12 +58,12 @@ class RdPagination {
58
58
*
59
59
* @param {string} selector The selector for HTML elements that will be render the pagination.
60
60
* @param {object} options The options (Required).
61
-
* @param {string} options.base_url The URL for use when generate page numbers with links (Required).
62
-
* Set the position where page numbers will be appears as URI segment or query string with `%PAGENUMBER%` placeholder.
63
-
* Example 1: `http://domain.tld/my-category/page/%PAGENUMBER%` This URL use page number as URI segment.
64
-
* Example 2: `http://domain.tld/my-category?page=%PAGENUMBER%` This URL use page number as query string.
65
-
* Example 3: `http://domain.tld/my-category?filter=some_filter_values&search=foobar&page=%PAGENUMBER%` This URL use page number as query string with other query strings in it, seperate each query string with `&` not just `&`.
66
-
* Example 4: `http://domain.tld/my-category?start=%PAGENUMBER%` This URL use page number as query string but use start as the name.
61
+
* @param {string} options.base_url The URL for use when generate page numbers with links (Required).<br>
62
+
* Set the position where page numbers will be appears as URI segment or query string with `%PAGENUMBER%` placeholder.<br>
63
+
* Example 1: `http://domain.tld/my-category/page/%PAGENUMBER%` This URL use page number as URI segment.<br>
64
+
* Example 2: `http://domain.tld/my-category?page=%PAGENUMBER%` This URL use page number as query string.<br>
65
+
* Example 3: `http://domain.tld/my-category?filter=some_filter_values&search=foobar&page=%PAGENUMBER%` This URL use page number as query string with other query strings in it, seperate each query string with `&` not just `&`.<br>
66
+
* Example 4: `http://domain.tld/my-category?start=%PAGENUMBER%` This URL use page number as query string but use start as the name.<br>
67
67
* You have to get the page number value and set its value to this class by call the "page_number_value" option.
68
68
* @param {number} options.page_number_value The current page number value (Required). This class cannot detect current page number automatically because of dynamic styles of URL. So, you have to manually set its value to this option.
69
69
* @param {number} options.total_records The total number of records (Required). This means "all" records by conditions with out the "LIMIT" or slices commands.
0 commit comments