/
function-page_options_.html
executable file
·205 lines (169 loc) · 5.43 KB
/
function-page_options_.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="generator" content="ApiGen 2.8.0">
<title>Function page_options_</title>
<script type="text/javascript" src="resources/combined.js?394153670"></script>
<script type="text/javascript" src="elementlist.js?4199484543"></script>
<link rel="stylesheet" type="text/css" media="all" href="resources/style.css?3505392360">
</head>
<body>
<div id="left">
<div id="menu">
<a href="index.html" title="Overview"><span>Overview</span></a>
<div id="groups">
<h3>Packages</h3>
<ul>
<li><a href="package-cache.html">cache</a>
</li>
<li><a href="package-classes.html">classes</a>
</li>
<li class="active"><a href="package-helpers.html">helpers<span></span></a>
<ul>
<li><a href="package-helpers.dt.html">dt</a>
</li>
<li><a href="package-helpers.form.html">form</a>
</li>
<li><a href="package-helpers.fs.html">fs</a>
</li>
<li><a href="package-helpers.html.html">html</a>
</li>
<li class="active"><a href="package-helpers.paginate.html">paginate</a>
</li>
<li><a href="package-helpers.url.html">url</a>
</li>
</ul></li>
<li><a href="package-liber.html">liber</a>
</li>
<li><a href="package-PHP.html">PHP</a>
</li>
</ul>
</div>
<hr>
<div id="elements">
<h3>Functions</h3>
<ul>
<li><a href="function-page_next_.html">page_next_</a></li>
<li><a href="function-page_num_.html">page_num_</a></li>
<li class="active"><a href="function-page_options_.html">page_options_</a></li>
<li><a href="function-page_prev_.html">page_prev_</a></li>
<li><a href="function-page_sort_.html">page_sort_</a></li>
<li><a href="function-page_url_.html">page_url_</a></li>
</ul>
</div>
</div>
</div>
<div id="splitter"></div>
<div id="right">
<div id="rightInner">
<form id="search">
<input type="hidden" name="cx" value="">
<input type="hidden" name="ie" value="UTF-8">
<input type="text" name="q" class="text">
<input type="submit" value="Search">
</form>
<div id="navigation">
<ul>
<li>
<a href="index.html" title="Overview"><span>Overview</span></a>
</li>
<li>
<a href="package-helpers.paginate.html" title="Summary of helpers\paginate"><span>Package</span></a>
</li>
<li class="active">
<span>Function</span> </li>
</ul>
<ul>
<li>
<a href="tree.html" title="Tree view of classes, interfaces, traits and exceptions"><span>Tree</span></a>
</li>
</ul>
<ul>
</ul>
</div>
<div id="content" class="function">
<h1>Function page_options_</h1>
<div class="description">
<p>Set or return options for paginating helper.</p>
<pre>
$options:
'url' => 'Url base to generate pagination.'
'rows_fetched' => 'Number of rows fetched that will be used as base to generate pages.'
'total' => 'Total pages avaliable.'
'rows' => 'Default number of rows for each page is 15.'
'param' => 'Query param name for pagination.'
'sort' => 'Current sorting field.'
'direct' => 'Current direction, that can be <asc|desc>.'
'page' => 'Current page number.'
'query' => 'Current search query terms.'
'url_query' => 'Aditional url query params like: name=John&age=25'
</pre>
<pre>
Usages:
<span
class="php-comment">// return array with all page options</span>
page_options_();
<span
class="php-comment">// set 10 as a number of rows per page</span>
page_options_(<span
class="php-quote">'rows'</span>, <span class="php-num">10</span>);
<span
class="php-comment">// set many options in once call</span>
page_options_( <span
class="php-keyword1">array</span>(<span
class="php-quote">'rows'</span> => <span class="php-num">10</span>, <span
class="php-quote">'url'</span> => <span
class="php-quote">'http://localhost/list'</span>) );
<span
class="php-comment">// return current url base</span>
page_options_(<span
class="php-quote">'url'</span>);
</pre>
</div>
<div class="info">
<b>Package:</b> <a href="package-helpers.html">helpers</a>\<a href="package-helpers.paginate.html">paginate</a><br>
<b>Copyright:</b>
<a
href="mailto:djalmaoliveira@gmail.com">djalmaoliveira@<!-- -->gmail.com</a><br>
<b>Author:</b>
<a
href="mailto:djalmaoliveira@gmail.com">djalmaoliveira@<!-- -->gmail.com</a><br>
<b>Located at</b> <a href="source-function-page_options_.html#11-86" title="Go to source code">helper/Paginate.php</a><br>
</div>
<table class="summary" id="parameters">
<caption>Parameters summary</caption>
<tr id="$options">
<td class="name"><code>array|string</code></td>
<td class="value"><code><var>$options</var> = <span class="php-keyword1">null</span></code></td>
<td>
Paginating options.
</td>
</tr>
<tr id="$value">
<td class="name"><code>string</code></td>
<td class="value"><code><var>$value</var> = <span class="php-keyword1">null</span></code></td>
<td>
Value of option.
</td>
</tr>
</table>
<table class="summary" id="returns">
<caption>Return value summary</caption>
<tr>
<td class="name"><code>
array
</code></td>
<td>
| void
</td>
</tr>
</table>
</div>
<div id="footer">
API documentation generated by <a href="http://apigen.org">ApiGen 2.8.0</a>
</div>
</div>
</div>
</body>
</html>