1 |
jonen |
1.2 |
<?xml version="1.0" encoding="iso-8859-1"?> |
2 |
|
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
3 |
|
|
<html xmlns="http://www.w3.org/1999/xhtml"> |
4 |
|
|
<head> |
5 |
|
|
<!-- template designed by Marco Von Ballmoos --> |
6 |
|
|
<title>Docs For Class FormContent</title> |
7 |
|
|
<link rel="stylesheet" href="../../media/stylesheet.css" /> |
8 |
|
|
<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/> |
9 |
|
|
</head> |
10 |
|
|
<body> |
11 |
|
|
<div class="page-body"> |
12 |
|
|
<h2 class="class-name">Class FormContent</h2> |
13 |
|
|
|
14 |
|
|
<a name="sec-description"></a> |
15 |
|
|
<div class="info-box"> |
16 |
|
|
<div class="info-box-title">Description</div> |
17 |
|
|
<div class="nav-bar"> |
18 |
|
|
<span class="disabled">Description</span> | |
19 |
|
|
<a href="#sec-descendents">Descendents</a> |
20 |
|
|
| <a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>) |
21 |
|
|
| <a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>) |
22 |
|
|
|
23 |
|
|
</div> |
24 |
|
|
<div class="info-box-body"> |
25 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
26 |
|
|
<p class="short-description">This class is used to build and render the form.</p> |
27 |
|
|
<p class="description"><p>It builds a form by creating FormElement objects which have automatic validation. It leaves the layout of the form up to the child class. It has a mechanism in place to automagically show a confirmation 'page' after the data has been submitted and validated. It also provides a hook for any 'back end' validation of data. Finally, it provides a function for handling the action of the form, which only gets call after ALL validation has passed.</p><p>Functions:</p><p>form_init_elements() - This function is used to build the FormElement objects that will be used by the form. This function is called EVERY time the FormContent class is instantiated. After you create the FormElement, you call the FormContent::add_element() method, to add the FormElement object to the form. You will then call the 2 methods FormContent::element_label() and FormContent::element_form() to get access to the FormElement's label and form field respectively.</p><p>form_init_data() - This is called only the first time the form is encountered. It Allows you to populate the FormElements with data from a DB for example. You would use FormContent::set_element_value() or FormContent::set_hidden_element_value() inside here.</p><p>form() - This is the method that gets called to build the layout for your form. Typically you use a table and add the label in the first <td> and the form field itself in the 2nd <td>. So there are 2 methods in the FormContent object that allow u to get access to the FormElements label, and form field. FormContent::element_label() and FormContent::element_form().</p><p>form_backend_validation() - This method enables you to do any "back end" validation of data. Such as, check for a duplicate in the DB on a create/new form. This is called after the FormElement's validation methods have passed.</p><p>form_action() - This method is called after ALL validation was successfull, including each FormElement object's validation methods, as well as the FormContent::form_backend_validation()</p></p> |
28 |
|
|
<p class="notes"> |
29 |
|
|
Located in <a class="field" href="_form_FormContent_inc.html">Program_Root/form/FormContent.inc</a> (line <span class="field">77</span>) |
30 |
|
|
</p> |
31 |
|
|
|
32 |
|
|
|
33 |
|
|
<pre></pre> |
34 |
|
|
|
35 |
|
|
</div> |
36 |
|
|
</div> |
37 |
|
|
|
38 |
|
|
<a name="sec-descendents"></a> |
39 |
|
|
<div class="info-box"> |
40 |
|
|
<div class="info-box-title">Direct descendents</div> |
41 |
|
|
<div class="nav-bar"> |
42 |
|
|
<a href="#sec-description">Description</a> | |
43 |
|
|
<span class="disabled">Descendents</span> |
44 |
|
|
| <a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>) |
45 |
|
|
| <a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>) |
46 |
|
|
|
47 |
|
|
</div> |
48 |
|
|
<div class="info-box-body"> |
49 |
|
|
<table cellpadding="2" cellspacing="0" class="class-table"> |
50 |
|
|
<tr> |
51 |
|
|
<th class="class-table-header">Class</th> |
52 |
|
|
<th class="class-table-header">Description</th> |
53 |
|
|
</tr> |
54 |
|
|
<tr> |
55 |
|
|
<td style="padding-right: 2em"><a href="../../phpHtmlLib/form-examples/AccountForm.html">AccountForm</a></td> |
56 |
|
|
<td> |
57 |
|
|
This is the Class that handles the building of the Form itself. It creates the Form Elements inside the form_init_elements() method. |
58 |
|
|
</td> |
59 |
|
|
</tr> |
60 |
|
|
<tr> |
61 |
|
|
<td style="padding-right: 2em"><a href="../../phpHtmlLib/FormProcessing/StandardFormContent.html">StandardFormContent</a></td> |
62 |
|
|
<td> |
63 |
|
|
This is a child of the FormContent class to provide a 'standard' look and feel for forms. |
64 |
|
|
</td> |
65 |
|
|
</tr> |
66 |
|
|
</table> |
67 |
|
|
</div> |
68 |
|
|
</div> |
69 |
|
|
|
70 |
|
|
<a name="sec-var-summary"></a> |
71 |
|
|
<div class="info-box"> |
72 |
|
|
<div class="info-box-title">Variable Summary</span></div> |
73 |
|
|
<div class="nav-bar"> |
74 |
|
|
<a href="#sec-description">Description</a> | |
75 |
|
|
<a href="#sec-descendents">Descendents</a> | |
76 |
|
|
<span class="disabled">Vars</span> (<a href="#sec-vars">details</a>) |
77 |
|
|
| |
78 |
|
|
<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>) |
79 |
|
|
|
80 |
|
|
</div> |
81 |
|
|
<div class="info-box-body"> |
82 |
|
|
<div class="var-summary"> |
83 |
|
|
<div class="var-title"> |
84 |
|
|
<span class="var-type">mixed</span> |
85 |
|
|
<a href="#$_action_counter" title="details" class="var-name">$_action_counter</a> |
86 |
|
|
</div> |
87 |
|
|
<div class="var-title"> |
88 |
|
|
<span class="var-type">mixed</span> |
89 |
|
|
<a href="#$_action_message" title="details" class="var-name">$_action_message</a> |
90 |
|
|
</div> |
91 |
|
|
<div class="var-title"> |
92 |
|
|
<span class="var-type">mixed</span> |
93 |
|
|
<a href="#$_cancel_action" title="details" class="var-name">$_cancel_action</a> |
94 |
|
|
</div> |
95 |
|
|
<div class="var-title"> |
96 |
|
|
<span class="var-type">mixed</span> |
97 |
|
|
<a href="#$_default_label_css" title="details" class="var-name">$_default_label_css</a> |
98 |
|
|
</div> |
99 |
|
|
<div class="var-title"> |
100 |
|
|
<span class="var-type">mixed</span> |
101 |
|
|
<a href="#$_elements" title="details" class="var-name">$_elements</a> |
102 |
|
|
</div> |
103 |
|
|
<div class="var-title"> |
104 |
|
|
<span class="var-type">mixed</span> |
105 |
|
|
<a href="#$_error_label_css" title="details" class="var-name">$_error_label_css</a> |
106 |
|
|
</div> |
107 |
|
|
<div class="var-title"> |
108 |
|
|
<span class="var-type">mixed</span> |
109 |
|
|
<a href="#$_form_errors_title" title="details" class="var-name">$_form_errors_title</a> |
110 |
|
|
</div> |
111 |
|
|
<div class="var-title"> |
112 |
|
|
<span class="var-type">mixed</span> |
113 |
|
|
<a href="#$_form_errors_width" title="details" class="var-name">$_form_errors_width</a> |
114 |
|
|
</div> |
115 |
|
|
<div class="var-title"> |
116 |
|
|
<span class="var-type">mixed</span> |
117 |
|
|
<a href="#$_form_name" title="details" class="var-name">$_form_name</a> |
118 |
|
|
</div> |
119 |
|
|
<div class="var-title"> |
120 |
|
|
<span class="var-type">mixed</span> |
121 |
|
|
<a href="#$_has_confirm" title="details" class="var-name">$_has_confirm</a> |
122 |
|
|
</div> |
123 |
|
|
<div class="var-title"> |
124 |
|
|
<span class="var-type">mixed</span> |
125 |
|
|
<a href="#$_hidden_elements" title="details" class="var-name">$_hidden_elements</a> |
126 |
|
|
</div> |
127 |
|
|
<div class="var-title"> |
128 |
|
|
<span class="var-type">mixed</span> |
129 |
|
|
<a href="#$_required_field_marker" title="details" class="var-name">$_required_field_marker</a> |
130 |
|
|
</div> |
131 |
|
|
<div class="var-title"> |
132 |
|
|
<span class="var-type">mixed</span> |
133 |
|
|
<a href="#$_required_field_text" title="details" class="var-name">$_required_field_text</a> |
134 |
|
|
</div> |
135 |
|
|
<div class="var-title"> |
136 |
|
|
<span class="var-type">mixed</span> |
137 |
|
|
<a href="#$_stripslashes" title="details" class="var-name">$_stripslashes</a> |
138 |
|
|
</div> |
139 |
|
|
<div class="var-title"> |
140 |
|
|
<span class="var-type">mixed</span> |
141 |
|
|
<a href="#$_width" title="details" class="var-name">$_width</a> |
142 |
|
|
</div> |
143 |
|
|
</div> |
144 |
|
|
</div> |
145 |
|
|
</div> |
146 |
|
|
|
147 |
|
|
<a name="sec-method-summary"></a> |
148 |
|
|
<div class="info-box"> |
149 |
|
|
<div class="info-box-title">Method Summary</span></div> |
150 |
|
|
<div class="nav-bar"> |
151 |
|
|
<a href="#sec-description">Description</a> | |
152 |
|
|
<a href="#sec-descendents">Descendents</a> | |
153 |
|
|
<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>) |
154 |
|
|
|
155 |
|
|
| |
156 |
|
|
<span class="disabled">Methods</span> (<a href="#sec-methods">details</a>) |
157 |
|
|
</div> |
158 |
|
|
<div class="info-box-body"> |
159 |
|
|
<div class="method-summary"> |
160 |
|
|
|
161 |
|
|
<div class="method-definition"> |
162 |
|
|
<span class="method-result">void</span> |
163 |
|
|
<a href="#FormContent" title="details" class="method-name">FormContent</a> |
164 |
|
|
([<span class="var-type">mixed</span> <span class="var-name">$width</span> = <span class="var-default">"100%"</span>], [<span class="var-type">mixed</span> <span class="var-name">$cancel_action</span> = <span class="var-default">NULL</span>]) |
165 |
|
|
</div> |
166 |
|
|
|
167 |
|
|
<div class="method-definition"> |
168 |
|
|
<span class="method-result"><a href="../../phpHtmlLib/INPUTtag.html">INPUTtag</a></span> |
169 |
|
|
<a href="#add_action" title="details" class="method-name">add_action</a> |
170 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>, [<span class="var-type">bool</span> <span class="var-name">$disabled</span> = <span class="var-default">false</span>], [<span class="var-type">string</span> <span class="var-name">$submit_function</span> = <span class="var-default">false</span>], [<span class="var-type">boolean</span> <span class="var-name">$disable_on_submit</span> = <span class="var-default">TRUE</span>]) |
171 |
|
|
</div> |
172 |
|
|
|
173 |
|
|
<div class="method-definition"> |
174 |
|
|
<span class="method-result">form</span> |
175 |
|
|
<a href="#add_cancel" title="details" class="method-name">add_cancel</a> |
176 |
|
|
(<span class="var-type">string</span> <span class="var-name">0</span>) |
177 |
|
|
</div> |
178 |
|
|
|
179 |
|
|
<div class="method-definition"> |
180 |
|
|
<span class="method-result">void</span> |
181 |
|
|
<a href="#add_element" title="details" class="method-name">add_element</a> |
182 |
|
|
(<span class="var-type"><a href="../../phpHtmlLib/FormProcessing/FormElement.html">FormElement</a></span> <span class="var-name">&$element</span>) |
183 |
|
|
</div> |
184 |
|
|
|
185 |
|
|
<div class="method-definition"> |
186 |
|
|
<span class="method-result">void</span> |
187 |
|
|
<a href="#add_error" title="details" class="method-name">add_error</a> |
188 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>, <span class="var-type">string</span> <span class="var-name">$message</span>) |
189 |
|
|
</div> |
190 |
|
|
|
191 |
|
|
<div class="method-definition"> |
192 |
|
|
<span class="method-result"><a href="../../phpHtmlLib/ContainerWidget.html">ContainerWidget</a></span> |
193 |
|
|
<a href="#add_hidden_action" title="details" class="method-name">add_hidden_action</a> |
194 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>, <span class="var-type">string</span> <span class="var-name">$action</span>, [<span class="var-type">boolean</span> <span class="var-name">$disable_on_submit</span> = <span class="var-default">TRUE</span>]) |
195 |
|
|
</div> |
196 |
|
|
|
197 |
|
|
<div class="method-definition"> |
198 |
|
|
<span class="method-result">void</span> |
199 |
|
|
<a href="#add_hidden_element" title="details" class="method-name">add_hidden_element</a> |
200 |
|
|
(<span class="var-type"><a href="../../phpHtmlLib/FormProcessing/FormElement.html">FormElement</a></span> <span class="var-name">$label</span>, [<span class="var-type">mixed</span> <span class="var-name">$value</span> = <span class="var-default">NULL</span>]) |
201 |
|
|
</div> |
202 |
|
|
|
203 |
|
|
<div class="method-definition"> |
204 |
|
|
<span class="method-result"><a href="../../phpHtmlLib/Atag.html">Atag</a></span> |
205 |
|
|
<a href="#add_image_action" title="details" class="method-name">add_image_action</a> |
206 |
|
|
(<span class="var-type">string</span> <span class="var-name">$image_name</span>, <span class="var-type">string</span> <span class="var-name">$action</span>, [<span class="var-type">boolean</span> <span class="var-name">$disable_on_submit</span> = <span class="var-default">TRUE</span>]) |
207 |
|
|
</div> |
208 |
|
|
|
209 |
|
|
<div class="method-definition"> |
210 |
|
|
<span class="method-result">void</span> |
211 |
|
|
<a href="#build_confirm_table" title="details" class="method-name">build_confirm_table</a> |
212 |
|
|
(<span class="var-type"><a href="../../phpHtmlLib/InfoTable.html">InfoTable</a></span> <span class="var-name">&$table</span>) |
213 |
|
|
</div> |
214 |
|
|
|
215 |
|
|
<div class="method-definition"> |
216 |
|
|
<span class="method-result">Object</span> |
217 |
|
|
<a href="#element_form" title="details" class="method-name">element_form</a> |
218 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>) |
219 |
|
|
</div> |
220 |
|
|
|
221 |
|
|
<div class="method-definition"> |
222 |
|
|
<span class="method-result">Object</span> |
223 |
|
|
<a href="#element_label" title="details" class="method-name">element_label</a> |
224 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>) |
225 |
|
|
</div> |
226 |
|
|
|
227 |
|
|
<div class="method-definition"> |
228 |
|
|
<span class="method-result"><a href="../../phpHtmlLib/Container.html">Container</a></span> |
229 |
|
|
<a href="#form" title="details" class="method-name">form</a> |
230 |
|
|
() |
231 |
|
|
</div> |
232 |
|
|
|
233 |
|
|
<div class="method-definition"> |
234 |
|
|
<span class="method-result">boolean</span> |
235 |
|
|
<a href="#form_action" title="details" class="method-name">form_action</a> |
236 |
|
|
(<span class="var-type">array</span> <span class="var-name">0</span>) |
237 |
|
|
</div> |
238 |
|
|
|
239 |
|
|
<div class="method-definition"> |
240 |
|
|
<span class="method-result">boolean</span> |
241 |
|
|
<a href="#form_backend_validation" title="details" class="method-name">form_backend_validation</a> |
242 |
|
|
() |
243 |
|
|
</div> |
244 |
|
|
|
245 |
|
|
<div class="method-definition"> |
246 |
|
|
<span class="method-result">mixed</span> |
247 |
|
|
<a href="#form_confirm" title="details" class="method-name">form_confirm</a> |
248 |
|
|
([<span class="var-type">string</span> <span class="var-name">$title</span> = <span class="var-default">"Form Confirmation"</span>], [<span class="var-type">boolean</span> <span class="var-name">$show_buttons</span> = <span class="var-default">TRUE</span>]) |
249 |
|
|
</div> |
250 |
|
|
|
251 |
|
|
<div class="method-definition"> |
252 |
|
|
<span class="method-result"><a href="../../phpHtmlLib/TABLEtag.html">TABLEtag</a></span> |
253 |
|
|
<a href="#form_errors" title="details" class="method-name">form_errors</a> |
254 |
|
|
() |
255 |
|
|
</div> |
256 |
|
|
|
257 |
|
|
<div class="method-definition"> |
258 |
|
|
<span class="method-result">void</span> |
259 |
|
|
<a href="#form_init_data" title="details" class="method-name">form_init_data</a> |
260 |
|
|
() |
261 |
|
|
</div> |
262 |
|
|
|
263 |
|
|
<div class="method-definition"> |
264 |
|
|
<span class="method-result">void</span> |
265 |
|
|
<a href="#form_init_elements" title="details" class="method-name">form_init_elements</a> |
266 |
|
|
() |
267 |
|
|
</div> |
268 |
|
|
|
269 |
|
|
<div class="method-definition"> |
270 |
|
|
<span class="method-result">mixed</span> |
271 |
|
|
<a href="#form_success" title="details" class="method-name">form_success</a> |
272 |
|
|
() |
273 |
|
|
</div> |
274 |
|
|
|
275 |
|
|
<div class="method-definition"> |
276 |
|
|
<span class="method-result">string</span> |
277 |
|
|
<a href="#get_action" title="details" class="method-name">get_action</a> |
278 |
|
|
() |
279 |
|
|
</div> |
280 |
|
|
|
281 |
|
|
<div class="method-definition"> |
282 |
|
|
<span class="method-result">string</span> |
283 |
|
|
<a href="#get_default_css" title="details" class="method-name">get_default_css</a> |
284 |
|
|
() |
285 |
|
|
</div> |
286 |
|
|
|
287 |
|
|
<div class="method-definition"> |
288 |
|
|
<span class="method-result">Object</span> |
289 |
|
|
<a href="#get_element" title="details" class="method-name">&get_element</a> |
290 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>) |
291 |
|
|
</div> |
292 |
|
|
|
293 |
|
|
<div class="method-definition"> |
294 |
|
|
<span class="method-result">value</span> |
295 |
|
|
<a href="#get_element_value" title="details" class="method-name">get_element_value</a> |
296 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>) |
297 |
|
|
</div> |
298 |
|
|
|
299 |
|
|
<div class="method-definition"> |
300 |
|
|
<span class="method-result">array</span> |
301 |
|
|
<a href="#get_error_array" title="details" class="method-name">get_error_array</a> |
302 |
|
|
() |
303 |
|
|
</div> |
304 |
|
|
|
305 |
|
|
<div class="method-definition"> |
306 |
|
|
<span class="method-result">int</span> |
307 |
|
|
<a href="#get_form_errors_width" title="details" class="method-name">get_form_errors_width</a> |
308 |
|
|
() |
309 |
|
|
</div> |
310 |
|
|
|
311 |
|
|
<div class="method-definition"> |
312 |
|
|
<span class="method-result">value</span> |
313 |
|
|
<a href="#get_hidden_element_value" title="details" class="method-name">get_hidden_element_value</a> |
314 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>) |
315 |
|
|
</div> |
316 |
|
|
|
317 |
|
|
<div class="method-definition"> |
318 |
|
|
<span class="method-result">void</span> |
319 |
|
|
<a href="#get_required_fields_text" title="details" class="method-name">get_required_fields_text</a> |
320 |
|
|
() |
321 |
|
|
</div> |
322 |
|
|
|
323 |
|
|
<div class="method-definition"> |
324 |
|
|
<span class="method-result">boolean</span> |
325 |
|
|
<a href="#has_confirm" title="details" class="method-name">has_confirm</a> |
326 |
|
|
() |
327 |
|
|
</div> |
328 |
|
|
|
329 |
|
|
<div class="method-definition"> |
330 |
|
|
<span class="method-result">Object</span> |
331 |
|
|
<a href="#hidden_element_label" title="details" class="method-name">hidden_element_label</a> |
332 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>) |
333 |
|
|
</div> |
334 |
|
|
|
335 |
|
|
<div class="method-definition"> |
336 |
|
|
<span class="method-result">string</span> |
337 |
|
|
<a href="#javascript" title="details" class="method-name">javascript</a> |
338 |
|
|
() |
339 |
|
|
</div> |
340 |
|
|
|
341 |
|
|
<div class="method-definition"> |
342 |
|
|
<span class="method-result">TRUE</span> |
343 |
|
|
<a href="#pre_confirm" title="details" class="method-name">pre_confirm</a> |
344 |
|
|
() |
345 |
|
|
</div> |
346 |
|
|
|
347 |
|
|
<div class="method-definition"> |
348 |
|
|
<span class="method-result">void</span> |
349 |
|
|
<a href="#set_action" title="details" class="method-name">set_action</a> |
350 |
|
|
(<span class="var-type">string</span> <span class="var-name">$action</span>) |
351 |
|
|
</div> |
352 |
|
|
|
353 |
|
|
<div class="method-definition"> |
354 |
|
|
<span class="method-result">void</span> |
355 |
|
|
<a href="#set_action_message" title="details" class="method-name">set_action_message</a> |
356 |
|
|
(<span class="var-type">string</span> <span class="var-name">$message</span>) |
357 |
|
|
</div> |
358 |
|
|
|
359 |
|
|
<div class="method-definition"> |
360 |
|
|
<span class="method-result">void</span> |
361 |
|
|
<a href="#set_cancel_action" title="details" class="method-name">set_cancel_action</a> |
362 |
|
|
(<span class="var-type">string</span> <span class="var-name">$action</span>) |
363 |
|
|
</div> |
364 |
|
|
|
365 |
|
|
<div class="method-definition"> |
366 |
|
|
<span class="method-result">void</span> |
367 |
|
|
<a href="#set_confirm" title="details" class="method-name">set_confirm</a> |
368 |
|
|
([<span class="var-type">boolean</span> <span class="var-name">$flag</span> = <span class="var-default">TRUE</span>]) |
369 |
|
|
</div> |
370 |
|
|
|
371 |
|
|
<div class="method-definition"> |
372 |
|
|
<span class="method-result">void</span> |
373 |
|
|
<a href="#set_default_css" title="details" class="method-name">set_default_css</a> |
374 |
|
|
(<span class="var-type">string</span> <span class="var-name">$css</span>) |
375 |
|
|
</div> |
376 |
|
|
|
377 |
|
|
<div class="method-definition"> |
378 |
|
|
<span class="method-result">void</span> |
379 |
|
|
<a href="#set_element_value" title="details" class="method-name">set_element_value</a> |
380 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>, <span class="var-type">value</span> <span class="var-name">$value</span>) |
381 |
|
|
</div> |
382 |
|
|
|
383 |
|
|
<div class="method-definition"> |
384 |
|
|
<span class="method-result">void</span> |
385 |
|
|
<a href="#set_error_css" title="details" class="method-name">set_error_css</a> |
386 |
|
|
(<span class="var-type">string</span> <span class="var-name">$css</span>) |
387 |
|
|
</div> |
388 |
|
|
|
389 |
|
|
<div class="method-definition"> |
390 |
|
|
<span class="method-result">void</span> |
391 |
|
|
<a href="#set_form_errors_title" title="details" class="method-name">set_form_errors_title</a> |
392 |
|
|
(<span class="var-type">string</span> <span class="var-name">$title</span>) |
393 |
|
|
</div> |
394 |
|
|
|
395 |
|
|
<div class="method-definition"> |
396 |
|
|
<span class="method-result">void</span> |
397 |
|
|
<a href="#set_form_errors_width" title="details" class="method-name">set_form_errors_width</a> |
398 |
|
|
(<span class="var-type">string</span> <span class="var-name">$width</span>) |
399 |
|
|
</div> |
400 |
|
|
|
401 |
|
|
<div class="method-definition"> |
402 |
|
|
<span class="method-result">void</span> |
403 |
|
|
<a href="#set_form_name" title="details" class="method-name">set_form_name</a> |
404 |
|
|
(<span class="var-type">mixed</span> <span class="var-name">$name</span>) |
405 |
|
|
</div> |
406 |
|
|
|
407 |
|
|
<div class="method-definition"> |
408 |
|
|
<span class="method-result">void</span> |
409 |
|
|
<a href="#set_form_width" title="details" class="method-name">set_form_width</a> |
410 |
|
|
(<span class="var-type">string</span> <span class="var-name">$width</span>) |
411 |
|
|
</div> |
412 |
|
|
|
413 |
|
|
<div class="method-definition"> |
414 |
|
|
<span class="method-result">void</span> |
415 |
|
|
<a href="#set_hidden_element_value" title="details" class="method-name">set_hidden_element_value</a> |
416 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>, <span class="var-type">value</span> <span class="var-name">$value</span>) |
417 |
|
|
</div> |
418 |
|
|
|
419 |
|
|
<div class="method-definition"> |
420 |
|
|
<span class="method-result">void</span> |
421 |
|
|
<a href="#set_required_marker" title="details" class="method-name">set_required_marker</a> |
422 |
|
|
(<span class="var-type">string</span> <span class="var-name">$marker</span>) |
423 |
|
|
</div> |
424 |
|
|
|
425 |
|
|
<div class="method-definition"> |
426 |
|
|
<span class="method-result">void</span> |
427 |
|
|
<a href="#set_required_text" title="details" class="method-name">set_required_text</a> |
428 |
|
|
(<span class="var-type">string</span> <span class="var-name">$text</span>) |
429 |
|
|
</div> |
430 |
|
|
|
431 |
|
|
<div class="method-definition"> |
432 |
|
|
<span class="method-result">void</span> |
433 |
|
|
<a href="#set_stripslashes" title="details" class="method-name">set_stripslashes</a> |
434 |
|
|
([<span class="var-type">boolean</span> <span class="var-name">$flag</span> = <span class="var-default">TRUE</span>]) |
435 |
|
|
</div> |
436 |
|
|
|
437 |
|
|
<div class="method-definition"> |
438 |
|
|
<span class="method-result">void</span> |
439 |
|
|
<a href="#_test_element" title="details" class="method-name">_test_element</a> |
440 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>, <span class="var-type">string</span> <span class="var-name">$method</span>, [<span class="var-type">boolean</span> <span class="var-name">$hidden</span> = <span class="var-default">FALSE</span>]) |
441 |
|
|
</div> |
442 |
|
|
</div> |
443 |
|
|
</div> |
444 |
|
|
</div> |
445 |
|
|
|
446 |
|
|
<a name="sec-vars"></a> |
447 |
|
|
<div class="info-box"> |
448 |
|
|
<div class="info-box-title">Variables</div> |
449 |
|
|
<div class="nav-bar"> |
450 |
|
|
<a href="#sec-description">Description</a> | |
451 |
|
|
<a href="#sec-descendents">Descendents</a> | |
452 |
|
|
<a href="#sec-var-summary">Vars</a> (<span class="disabled">details</span>) |
453 |
|
|
|
454 |
|
|
|
455 |
|
|
| |
456 |
|
|
<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>) |
457 |
|
|
|
458 |
|
|
</div> |
459 |
|
|
<div class="info-box-body"> |
460 |
|
|
<a name="var$_action_counter" id="$_action_counter"><!-- --></A> |
461 |
|
|
<div class="oddrow"> |
462 |
|
|
|
463 |
|
|
<div class="var-header"> |
464 |
|
|
<span class="var-title"> |
465 |
|
|
<span class="var-type">mixed</span> |
466 |
|
|
<span class="var-name">$_action_counter</span> |
467 |
|
|
= <span class="var-default"> 0</span> (line <span class="line-number">177</span>) |
468 |
|
|
</span> |
469 |
|
|
</div> |
470 |
|
|
|
471 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
472 |
|
|
<p class="short-description">This holds how many actions we have</p> |
473 |
|
|
<p class="description"><p>for this form content</p></p> |
474 |
|
|
|
475 |
|
|
|
476 |
|
|
|
477 |
|
|
|
478 |
|
|
|
479 |
|
|
</div> |
480 |
|
|
<a name="var$_action_message" id="$_action_message"><!-- --></A> |
481 |
|
|
<div class="evenrow"> |
482 |
|
|
|
483 |
|
|
<div class="var-header"> |
484 |
|
|
<span class="var-title"> |
485 |
|
|
<span class="var-type">mixed</span> |
486 |
|
|
<span class="var-name">$_action_message</span> |
487 |
|
|
= <span class="var-default"> ""</span> (line <span class="line-number">150</span>) |
488 |
|
|
</span> |
489 |
|
|
</div> |
490 |
|
|
|
491 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
492 |
|
|
<p class="short-description">The message that is set</p> |
493 |
|
|
<p class="description"><p>during the form_action</p></p> |
494 |
|
|
|
495 |
|
|
|
496 |
|
|
|
497 |
|
|
|
498 |
|
|
|
499 |
|
|
</div> |
500 |
|
|
<a name="var$_cancel_action" id="$_cancel_action"><!-- --></A> |
501 |
|
|
<div class="oddrow"> |
502 |
|
|
|
503 |
|
|
<div class="var-header"> |
504 |
|
|
<span class="var-title"> |
505 |
|
|
<span class="var-type">mixed</span> |
506 |
|
|
<span class="var-name">$_cancel_action</span> |
507 |
|
|
= <span class="var-default"> NULL</span> (line <span class="line-number">157</span>) |
508 |
|
|
</span> |
509 |
|
|
</div> |
510 |
|
|
|
511 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
512 |
|
|
<p class="short-description">The action to take opon clicking</p> |
513 |
|
|
<p class="description"><p>the "Cancel" button</p></p> |
514 |
|
|
|
515 |
|
|
|
516 |
|
|
|
517 |
|
|
|
518 |
|
|
|
519 |
|
|
</div> |
520 |
|
|
<a name="var$_default_label_css" id="$_default_label_css"><!-- --></A> |
521 |
|
|
<div class="evenrow"> |
522 |
|
|
|
523 |
|
|
<div class="var-header"> |
524 |
|
|
<span class="var-title"> |
525 |
|
|
<span class="var-type">mixed</span> |
526 |
|
|
<span class="var-name">$_default_label_css</span> |
527 |
|
|
= <span class="var-default"> "formlabel"</span> (line <span class="line-number">106</span>) |
528 |
|
|
</span> |
529 |
|
|
</div> |
530 |
|
|
|
531 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
532 |
|
|
<p class="short-description">This holds the default css class for form field label text.</p> |
533 |
|
|
|
534 |
|
|
|
535 |
|
|
|
536 |
|
|
|
537 |
|
|
|
538 |
|
|
</div> |
539 |
|
|
<a name="var$_elements" id="$_elements"><!-- --></A> |
540 |
|
|
<div class="oddrow"> |
541 |
|
|
|
542 |
|
|
<div class="var-header"> |
543 |
|
|
<span class="var-title"> |
544 |
|
|
<span class="var-type">mixed</span> |
545 |
|
|
<span class="var-name">$_elements</span> |
546 |
|
|
= <span class="var-default">array()</span> (line <span class="line-number">97</span>) |
547 |
|
|
</span> |
548 |
|
|
</div> |
549 |
|
|
|
550 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
551 |
|
|
<p class="short-description">This holds the array of</p> |
552 |
|
|
<p class="description"><p>non-hidden elements</p></p> |
553 |
|
|
|
554 |
|
|
|
555 |
|
|
|
556 |
|
|
|
557 |
|
|
|
558 |
|
|
</div> |
559 |
|
|
<a name="var$_error_label_css" id="$_error_label_css"><!-- --></A> |
560 |
|
|
<div class="evenrow"> |
561 |
|
|
|
562 |
|
|
<div class="var-header"> |
563 |
|
|
<span class="var-title"> |
564 |
|
|
<span class="var-type">mixed</span> |
565 |
|
|
<span class="var-name">$_error_label_css</span> |
566 |
|
|
= <span class="var-default"> "formlabelerror"</span> (line <span class="line-number">113</span>) |
567 |
|
|
</span> |
568 |
|
|
</div> |
569 |
|
|
|
570 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
571 |
|
|
<p class="short-description">This is the css class used</p> |
572 |
|
|
<p class="description"><p>for fields that have an error</p></p> |
573 |
|
|
|
574 |
|
|
|
575 |
|
|
|
576 |
|
|
|
577 |
|
|
|
578 |
|
|
</div> |
579 |
|
|
<a name="var$_form_errors_title" id="$_form_errors_title"><!-- --></A> |
580 |
|
|
<div class="oddrow"> |
581 |
|
|
|
582 |
|
|
<div class="var-header"> |
583 |
|
|
<span class="var-title"> |
584 |
|
|
<span class="var-type">mixed</span> |
585 |
|
|
<span class="var-name">$_form_errors_title</span> |
586 |
|
|
= <span class="var-default"> "Form Errors"</span> (line <span class="line-number">143</span>) |
587 |
|
|
</span> |
588 |
|
|
</div> |
589 |
|
|
|
590 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
591 |
|
|
<p class="short-description">The form errors table title</p> |
592 |
|
|
|
593 |
|
|
|
594 |
|
|
|
595 |
|
|
|
596 |
|
|
|
597 |
|
|
</div> |
598 |
|
|
<a name="var$_form_errors_width" id="$_form_errors_width"><!-- --></A> |
599 |
|
|
<div class="evenrow"> |
600 |
|
|
|
601 |
|
|
<div class="var-header"> |
602 |
|
|
<span class="var-title"> |
603 |
|
|
<span class="var-type">mixed</span> |
604 |
|
|
<span class="var-name">$_form_errors_width</span> |
605 |
|
|
= <span class="var-default"> null</span> (line <span class="line-number">137</span>) |
606 |
|
|
</span> |
607 |
|
|
</div> |
608 |
|
|
|
609 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
610 |
|
|
<p class="short-description">Holds the width (if any) of the errors table that will be rendered. If the value is null, the $this->_width value is used instead.</p> |
611 |
|
|
|
612 |
|
|
|
613 |
|
|
|
614 |
|
|
|
615 |
|
|
|
616 |
|
|
</div> |
617 |
|
|
<a name="var$_form_name" id="$_form_name"><!-- --></A> |
618 |
|
|
<div class="oddrow"> |
619 |
|
|
|
620 |
|
|
<div class="var-header"> |
621 |
|
|
<span class="var-title"> |
622 |
|
|
<span class="var-type">mixed</span> |
623 |
|
|
<span class="var-name">$_form_name</span> |
624 |
|
|
(line <span class="line-number">83</span>) |
625 |
|
|
</span> |
626 |
|
|
</div> |
627 |
|
|
|
628 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
629 |
|
|
<p class="short-description">This holds the name of the form</p> |
630 |
|
|
<p class="description"><p>for js that needs it</p></p> |
631 |
|
|
|
632 |
|
|
|
633 |
|
|
|
634 |
|
|
|
635 |
|
|
|
636 |
|
|
</div> |
637 |
|
|
<a name="var$_has_confirm" id="$_has_confirm"><!-- --></A> |
638 |
|
|
<div class="evenrow"> |
639 |
|
|
|
640 |
|
|
<div class="var-header"> |
641 |
|
|
<span class="var-title"> |
642 |
|
|
<span class="var-type">mixed</span> |
643 |
|
|
<span class="var-name">$_has_confirm</span> |
644 |
|
|
= <span class="var-default"> FALSE</span> (line <span class="line-number">120</span>) |
645 |
|
|
</span> |
646 |
|
|
</div> |
647 |
|
|
|
648 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
649 |
|
|
<p class="short-description">flag to let the FormProcessor</p> |
650 |
|
|
<p class="description"><p>object know this form has a confirmation page that is required</p></p> |
651 |
|
|
|
652 |
|
|
|
653 |
|
|
|
654 |
|
|
|
655 |
|
|
|
656 |
|
|
</div> |
657 |
|
|
<a name="var$_hidden_elements" id="$_hidden_elements"><!-- --></A> |
658 |
|
|
<div class="oddrow"> |
659 |
|
|
|
660 |
|
|
<div class="var-header"> |
661 |
|
|
<span class="var-title"> |
662 |
|
|
<span class="var-type">mixed</span> |
663 |
|
|
<span class="var-name">$_hidden_elements</span> |
664 |
|
|
= <span class="var-default">array()</span> (line <span class="line-number">91</span>) |
665 |
|
|
</span> |
666 |
|
|
</div> |
667 |
|
|
|
668 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
669 |
|
|
<p class="short-description">This holds the array of</p> |
670 |
|
|
<p class="description"><p>hidden form elements used in this form</p></p> |
671 |
|
|
|
672 |
|
|
|
673 |
|
|
|
674 |
|
|
|
675 |
|
|
|
676 |
|
|
</div> |
677 |
|
|
<a name="var$_required_field_marker" id="$_required_field_marker"><!-- --></A> |
678 |
|
|
<div class="evenrow"> |
679 |
|
|
|
680 |
|
|
<div class="var-header"> |
681 |
|
|
<span class="var-title"> |
682 |
|
|
<span class="var-type">mixed</span> |
683 |
|
|
<span class="var-name">$_required_field_marker</span> |
684 |
|
|
= <span class="var-default"> "*"</span> (line <span class="line-number">171</span>) |
685 |
|
|
</span> |
686 |
|
|
</div> |
687 |
|
|
|
688 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
689 |
|
|
<p class="short-description">marker for the required field</p> |
690 |
|
|
|
691 |
|
|
|
692 |
|
|
|
693 |
|
|
|
694 |
jonen |
1.1 |
|
695 |
jonen |
1.2 |
</div> |
696 |
|
|
<a name="var$_required_field_text" id="$_required_field_text"><!-- --></A> |
697 |
|
|
<div class="oddrow"> |
698 |
|
|
|
699 |
|
|
<div class="var-header"> |
700 |
|
|
<span class="var-title"> |
701 |
|
|
<span class="var-type">mixed</span> |
702 |
|
|
<span class="var-name">$_required_field_text</span> |
703 |
|
|
= <span class="var-default"> " - required field"</span> (line <span class="line-number">165</span>) |
704 |
|
|
</span> |
705 |
|
|
</div> |
706 |
jonen |
1.1 |
|
707 |
jonen |
1.2 |
<!-- ========== Info from phpDoc block ========= --> |
708 |
|
|
<p class="short-description">Text to show denoted required fields for the form.</p> |
709 |
|
|
|
710 |
|
|
|
711 |
|
|
|
712 |
|
|
|
713 |
jonen |
1.1 |
|
714 |
jonen |
1.2 |
</div> |
715 |
|
|
<a name="var$_stripslashes" id="$_stripslashes"><!-- --></A> |
716 |
|
|
<div class="evenrow"> |
717 |
|
|
|
718 |
|
|
<div class="var-header"> |
719 |
|
|
<span class="var-title"> |
720 |
|
|
<span class="var-type">mixed</span> |
721 |
|
|
<span class="var-name">$_stripslashes</span> |
722 |
|
|
= <span class="var-default"> FALSE</span> (line <span class="line-number">183</span>) |
723 |
|
|
</span> |
724 |
|
|
</div> |
725 |
jonen |
1.1 |
|
726 |
jonen |
1.2 |
<!-- ========== Info from phpDoc block ========= --> |
727 |
|
|
<p class="short-description">Automatically strip slashes from</p> |
728 |
|
|
<p class="description"><p>form values?</p></p> |
729 |
|
|
|
730 |
|
|
|
731 |
|
|
|
732 |
|
|
|
733 |
|
|
|
734 |
|
|
</div> |
735 |
|
|
<a name="var$_width" id="$_width"><!-- --></A> |
736 |
|
|
<div class="oddrow"> |
737 |
|
|
|
738 |
|
|
<div class="var-header"> |
739 |
|
|
<span class="var-title"> |
740 |
|
|
<span class="var-type">mixed</span> |
741 |
|
|
<span class="var-name">$_width</span> |
742 |
|
|
= <span class="var-default"> "600"</span> (line <span class="line-number">129</span>) |
743 |
|
|
</span> |
744 |
|
|
</div> |
745 |
jonen |
1.1 |
|
746 |
jonen |
1.2 |
<!-- ========== Info from phpDoc block ========= --> |
747 |
|
|
<p class="short-description">Holds the width to be used for the</p> |
748 |
|
|
<p class="description"><p>error table DEFAULT: 95%</p></p> |
749 |
|
|
|
750 |
|
|
|
751 |
|
|
|
752 |
|
|
|
753 |
jonen |
1.1 |
|
754 |
jonen |
1.2 |
</div> |
755 |
|
|
|
756 |
|
|
</div> |
757 |
|
|
</div> |
758 |
|
|
|
759 |
|
|
<a name="sec-methods"></a> |
760 |
|
|
<div class="info-box"> |
761 |
|
|
<div class="info-box-title">Methods</div> |
762 |
|
|
<div class="nav-bar"> |
763 |
|
|
<a href="#sec-description">Description</a> | |
764 |
|
|
<a href="#sec-descendents">Descendents</a> | |
765 |
|
|
<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>) |
766 |
|
|
<a href="#sec-method-summary">Methods</a> (<span class="disabled">details</span>) |
767 |
|
|
|
768 |
|
|
</div> |
769 |
|
|
<div class="info-box-body"> |
770 |
|
|
<A NAME='method_detail'></A> |
771 |
|
|
<a name="methodFormContent" id="FormContent"><!-- --></a> |
772 |
|
|
<div class="evenrow"> |
773 |
|
|
|
774 |
|
|
<div class="method-header"> |
775 |
|
|
<span class="method-title">Constructor FormContent</span> (line <span class="line-number">187</span>) |
776 |
|
|
</div> |
777 |
|
|
|
778 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
779 |
|
|
|
780 |
|
|
<div class="method-signature"> |
781 |
|
|
<span class="method-result">void</span> |
782 |
|
|
<span class="method-name"> |
783 |
|
|
FormContent |
784 |
|
|
</span> |
785 |
|
|
([<span class="var-type">mixed</span> <span class="var-name">$width</span> = <span class="var-default">"100%"</span>], [<span class="var-type">mixed</span> <span class="var-name">$cancel_action</span> = <span class="var-default">NULL</span>]) |
786 |
|
|
</div> |
787 |
|
|
|
788 |
|
|
|
789 |
|
|
|
790 |
|
|
</div> |
791 |
|
|
<a name="methodadd_action" id="add_action"><!-- --></a> |
792 |
|
|
<div class="oddrow"> |
793 |
|
|
|
794 |
|
|
<div class="method-header"> |
795 |
|
|
<span class="method-title">add_action</span> (line <span class="line-number">792</span>) |
796 |
|
|
</div> |
797 |
|
|
|
798 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
799 |
|
|
<p class="short-description">This function adds a form submit button with the appropriate action.</p> |
800 |
|
|
<ul class="tags"> |
801 |
|
|
<li><span class="field">return:</span> <p>object</p></li> |
802 |
|
|
</ul> |
803 |
|
|
|
804 |
|
|
<div class="method-signature"> |
805 |
|
|
<span class="method-result"><a href="../../phpHtmlLib/INPUTtag.html">INPUTtag</a></span> |
806 |
|
|
<span class="method-name"> |
807 |
|
|
add_action |
808 |
|
|
</span> |
809 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>, [<span class="var-type">bool</span> <span class="var-name">$disabled</span> = <span class="var-default">false</span>], [<span class="var-type">string</span> <span class="var-name">$submit_function</span> = <span class="var-default">false</span>], [<span class="var-type">boolean</span> <span class="var-name">$disable_on_submit</span> = <span class="var-default">TRUE</span>]) |
810 |
|
|
</div> |
811 |
|
|
|
812 |
|
|
<ul class="parameters"> |
813 |
|
|
<li> |
814 |
|
|
<span class="var-type">string</span> |
815 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>- the labe/action for the submit button.</p></span> </li> |
816 |
|
|
<li> |
817 |
|
|
<span class="var-type">bool</span> |
818 |
|
|
<span class="var-name">$disabled</span><span class="var-description">: <p>disable the button</p></span> </li> |
819 |
|
|
<li> |
820 |
|
|
<span class="var-type">string</span> |
821 |
|
|
<span class="var-name">$submit_function</span><span class="var-description">: <p>- the onSubmit function (if any)</p></span> </li> |
822 |
|
|
<li> |
823 |
|
|
<span class="var-type">boolean</span> |
824 |
|
|
<span class="var-name">$disable_on_submit</span><span class="var-description">: <p>- disable opon submit?</p></span> </li> |
825 |
|
|
</ul> |
826 |
|
|
|
827 |
|
|
|
828 |
|
|
</div> |
829 |
|
|
<a name="methodadd_cancel" id="add_cancel"><!-- --></a> |
830 |
|
|
<div class="evenrow"> |
831 |
|
|
|
832 |
|
|
<div class="method-header"> |
833 |
|
|
<span class="method-title">add_cancel</span> (line <span class="line-number">915</span>) |
834 |
|
|
</div> |
835 |
|
|
|
836 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
837 |
|
|
<p class="short-description">build a cancel button with a url to go to</p> |
838 |
|
|
<ul class="tags"> |
839 |
|
|
<li><span class="field">return:</span> <p>button</p></li> |
840 |
|
|
</ul> |
841 |
|
|
|
842 |
|
|
<div class="method-signature"> |
843 |
|
|
<span class="method-result">form</span> |
844 |
|
|
<span class="method-name"> |
845 |
|
|
add_cancel |
846 |
|
|
</span> |
847 |
|
|
(<span class="var-type">string</span> <span class="var-name">0</span>) |
848 |
|
|
</div> |
849 |
|
|
|
850 |
|
|
<ul class="parameters"> |
851 |
|
|
<li> |
852 |
|
|
<span class="var-type">string</span> |
853 |
|
|
<span class="var-name">0</span><span class="var-description">: <p>- the cancel action</p></span> </li> |
854 |
|
|
</ul> |
855 |
|
|
|
856 |
|
|
|
857 |
|
|
</div> |
858 |
|
|
<a name="methodadd_element" id="add_element"><!-- --></a> |
859 |
|
|
<div class="oddrow"> |
860 |
|
|
|
861 |
|
|
<div class="method-header"> |
862 |
|
|
<span class="method-title">add_element</span> (line <span class="line-number">461</span>) |
863 |
|
|
</div> |
864 |
|
|
|
865 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
866 |
|
|
<p class="short-description">This method is used to add a form element</p> |
867 |
|
|
|
868 |
|
|
<div class="method-signature"> |
869 |
|
|
<span class="method-result">void</span> |
870 |
|
|
<span class="method-name"> |
871 |
|
|
add_element |
872 |
|
|
</span> |
873 |
|
|
(<span class="var-type"><a href="../../phpHtmlLib/FormProcessing/FormElement.html">FormElement</a></span> <span class="var-name">&$element</span>) |
874 |
|
|
</div> |
875 |
|
|
|
876 |
|
|
<ul class="parameters"> |
877 |
|
|
<li> |
878 |
|
|
<span class="var-type"><a href="../../phpHtmlLib/FormProcessing/FormElement.html">FormElement</a></span> |
879 |
|
|
<span class="var-name">&$element</span><span class="var-description">: <p>object</p></span> </li> |
880 |
|
|
</ul> |
881 |
|
|
|
882 |
|
|
|
883 |
|
|
</div> |
884 |
|
|
<a name="methodadd_error" id="add_error"><!-- --></a> |
885 |
|
|
<div class="evenrow"> |
886 |
|
|
|
887 |
|
|
<div class="method-header"> |
888 |
|
|
<span class="method-title">add_error</span> (line <span class="line-number">589</span>) |
889 |
|
|
</div> |
890 |
|
|
|
891 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
892 |
|
|
<p class="short-description">This method is used to create a new error element during the call to form_action(). This enables us to do error handling during a transaction into a DB.</p> |
893 |
|
|
|
894 |
|
|
<div class="method-signature"> |
895 |
|
|
<span class="method-result">void</span> |
896 |
|
|
<span class="method-name"> |
897 |
|
|
add_error |
898 |
|
|
</span> |
899 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>, <span class="var-type">string</span> <span class="var-name">$message</span>) |
900 |
|
|
</div> |
901 |
|
|
|
902 |
|
|
<ul class="parameters"> |
903 |
|
|
<li> |
904 |
|
|
<span class="var-type">string</span> |
905 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>- the label</p></span> </li> |
906 |
|
|
<li> |
907 |
|
|
<span class="var-type">string</span> |
908 |
|
|
<span class="var-name">$message</span><span class="var-description">: <p>- the error message</p></span> </li> |
909 |
|
|
</ul> |
910 |
|
|
|
911 |
|
|
|
912 |
|
|
</div> |
913 |
|
|
<a name="methodadd_hidden_action" id="add_hidden_action"><!-- --></a> |
914 |
|
|
<div class="oddrow"> |
915 |
|
|
|
916 |
|
|
<div class="method-header"> |
917 |
|
|
<span class="method-title">add_hidden_action</span> (line <span class="line-number">844</span>) |
918 |
|
|
</div> |
919 |
|
|
|
920 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
921 |
|
|
<p class="short-description">This function adds a submit button that can have any label. It just makes the _form_action a hidden field.</p> |
922 |
|
|
<p class="description"><p>NOTE: you can only do this ONCE per form.</p></p> |
923 |
|
|
<ul class="tags"> |
924 |
|
|
<li><span class="field">return:</span> <p>object</p></li> |
925 |
|
|
</ul> |
926 |
|
|
|
927 |
|
|
<div class="method-signature"> |
928 |
|
|
<span class="method-result"><a href="../../phpHtmlLib/ContainerWidget.html">ContainerWidget</a></span> |
929 |
|
|
<span class="method-name"> |
930 |
|
|
add_hidden_action |
931 |
|
|
</span> |
932 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>, <span class="var-type">string</span> <span class="var-name">$action</span>, [<span class="var-type">boolean</span> <span class="var-name">$disable_on_submit</span> = <span class="var-default">TRUE</span>]) |
933 |
|
|
</div> |
934 |
|
|
|
935 |
|
|
<ul class="parameters"> |
936 |
|
|
<li> |
937 |
|
|
<span class="var-type">string</span> |
938 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>- the label of the button.</p></span> </li> |
939 |
|
|
<li> |
940 |
|
|
<span class="var-type">string</span> |
941 |
|
|
<span class="var-name">$action</span><span class="var-description">: <p>- the action value.</p></span> </li> |
942 |
|
|
<li> |
943 |
|
|
<span class="var-type">boolean</span> |
944 |
|
|
<span class="var-name">$disable_on_submit</span><span class="var-description">: <p>- disable opon submit?</p></span> </li> |
945 |
|
|
</ul> |
946 |
|
|
|
947 |
|
|
|
948 |
|
|
</div> |
949 |
|
|
<a name="methodadd_hidden_element" id="add_hidden_element"><!-- --></a> |
950 |
|
|
<div class="evenrow"> |
951 |
|
|
|
952 |
|
|
<div class="method-header"> |
953 |
|
|
<span class="method-title">add_hidden_element</span> (line <span class="line-number">474</span>) |
954 |
|
|
</div> |
955 |
|
|
|
956 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
957 |
|
|
<p class="short-description">This method is used to add a hidden form field</p> |
958 |
|
|
|
959 |
|
|
<div class="method-signature"> |
960 |
|
|
<span class="method-result">void</span> |
961 |
|
|
<span class="method-name"> |
962 |
|
|
add_hidden_element |
963 |
|
|
</span> |
964 |
|
|
(<span class="var-type"><a href="../../phpHtmlLib/FormProcessing/FormElement.html">FormElement</a></span> <span class="var-name">$label</span>, [<span class="var-type">mixed</span> <span class="var-name">$value</span> = <span class="var-default">NULL</span>]) |
965 |
|
|
</div> |
966 |
|
|
|
967 |
|
|
<ul class="parameters"> |
968 |
|
|
<li> |
969 |
|
|
<span class="var-type"><a href="../../phpHtmlLib/FormProcessing/FormElement.html">FormElement</a></span> |
970 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>object</p></span> </li> |
971 |
|
|
</ul> |
972 |
|
|
|
973 |
|
|
|
974 |
|
|
</div> |
975 |
|
|
<a name="methodadd_image_action" id="add_image_action"><!-- --></a> |
976 |
|
|
<div class="oddrow"> |
977 |
|
|
|
978 |
|
|
<div class="method-header"> |
979 |
|
|
<span class="method-title">add_image_action</span> (line <span class="line-number">881</span>) |
980 |
|
|
</div> |
981 |
|
|
|
982 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
983 |
|
|
<p class="short-description">This function adds an action as an image to submit the form.</p> |
984 |
|
|
<ul class="tags"> |
985 |
|
|
<li><span class="field">return:</span> <p>object</p></li> |
986 |
|
|
</ul> |
987 |
|
|
|
988 |
|
|
<div class="method-signature"> |
989 |
|
|
<span class="method-result"><a href="../../phpHtmlLib/Atag.html">Atag</a></span> |
990 |
|
|
<span class="method-name"> |
991 |
|
|
add_image_action |
992 |
|
|
</span> |
993 |
|
|
(<span class="var-type">string</span> <span class="var-name">$image_name</span>, <span class="var-type">string</span> <span class="var-name">$action</span>, [<span class="var-type">boolean</span> <span class="var-name">$disable_on_submit</span> = <span class="var-default">TRUE</span>]) |
994 |
|
|
</div> |
995 |
|
|
|
996 |
|
|
<ul class="parameters"> |
997 |
|
|
<li> |
998 |
|
|
<span class="var-type">string</span> |
999 |
|
|
<span class="var-name">$image_name</span><span class="var-description">: <p>- the image name path</p></span> </li> |
1000 |
|
|
<li> |
1001 |
|
|
<span class="var-type">string</span> |
1002 |
|
|
<span class="var-name">$action</span><span class="var-description">: <p>- the action</p></span> </li> |
1003 |
|
|
<li> |
1004 |
|
|
<span class="var-type">boolean</span> |
1005 |
|
|
<span class="var-name">$disable_on_submit</span><span class="var-description">: <p>- disable opon submit?</p></span> </li> |
1006 |
|
|
</ul> |
1007 |
|
|
|
1008 |
|
|
|
1009 |
|
|
</div> |
1010 |
|
|
<a name="methodbuild_confirm_table" id="build_confirm_table"><!-- --></a> |
1011 |
|
|
<div class="evenrow"> |
1012 |
|
|
|
1013 |
|
|
<div class="method-header"> |
1014 |
|
|
<span class="method-title">build_confirm_table</span> (line <span class="line-number">310</span>) |
1015 |
|
|
</div> |
1016 |
|
|
|
1017 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1018 |
|
|
<p class="short-description">This method allows the child to ovveride the default confirm data. By default the form_confirm() will show ALL FormElements. This is prolly not good in case of a form where a password exists.</p> |
1019 |
|
|
|
1020 |
|
|
<div class="method-signature"> |
1021 |
|
|
<span class="method-result">void</span> |
1022 |
|
|
<span class="method-name"> |
1023 |
|
|
build_confirm_table |
1024 |
|
|
</span> |
1025 |
|
|
(<span class="var-type"><a href="../../phpHtmlLib/InfoTable.html">InfoTable</a></span> <span class="var-name">&$table</span>) |
1026 |
|
|
</div> |
1027 |
|
|
|
1028 |
|
|
<ul class="parameters"> |
1029 |
|
|
<li> |
1030 |
|
|
<span class="var-type"><a href="../../phpHtmlLib/InfoTable.html">InfoTable</a></span> |
1031 |
|
|
<span class="var-name">&$table</span><span class="var-description">: <p>object</p></span> </li> |
1032 |
|
|
</ul> |
1033 |
|
|
|
1034 |
|
|
|
1035 |
|
|
</div> |
1036 |
|
|
<a name="methodelement_form" id="element_form"><!-- --></a> |
1037 |
|
|
<div class="oddrow"> |
1038 |
|
|
|
1039 |
|
|
<div class="method-header"> |
1040 |
|
|
<span class="method-title">element_form</span> (line <span class="line-number">512</span>) |
1041 |
|
|
</div> |
1042 |
|
|
|
1043 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1044 |
|
|
<p class="short-description">This method returns the actual form object that renders the form field.</p> |
1045 |
|
|
<p class="description"><p>Such as an INPUTtag object.</p></p> |
1046 |
|
|
|
1047 |
|
|
<div class="method-signature"> |
1048 |
|
|
<span class="method-result">Object</span> |
1049 |
|
|
<span class="method-name"> |
1050 |
|
|
element_form |
1051 |
|
|
</span> |
1052 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>) |
1053 |
|
|
</div> |
1054 |
|
|
|
1055 |
|
|
<ul class="parameters"> |
1056 |
|
|
<li> |
1057 |
|
|
<span class="var-type">string</span> |
1058 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>- the element's label</p></span> </li> |
1059 |
|
|
</ul> |
1060 |
|
|
|
1061 |
|
|
|
1062 |
|
|
</div> |
1063 |
|
|
<a name="methodelement_label" id="element_label"><!-- --></a> |
1064 |
|
|
<div class="evenrow"> |
1065 |
|
|
|
1066 |
|
|
<div class="method-header"> |
1067 |
|
|
<span class="method-title">element_label</span> (line <span class="line-number">487</span>) |
1068 |
|
|
</div> |
1069 |
|
|
|
1070 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1071 |
|
|
<p class="short-description">This method returns the label object for a visible form element.</p> |
1072 |
|
|
|
1073 |
|
|
<div class="method-signature"> |
1074 |
|
|
<span class="method-result">Object</span> |
1075 |
|
|
<span class="method-name"> |
1076 |
|
|
element_label |
1077 |
|
|
</span> |
1078 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>) |
1079 |
|
|
</div> |
1080 |
|
|
|
1081 |
|
|
<ul class="parameters"> |
1082 |
|
|
<li> |
1083 |
|
|
<span class="var-type">string</span> |
1084 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>- the element's label</p></span> </li> |
1085 |
|
|
</ul> |
1086 |
|
|
|
1087 |
|
|
|
1088 |
|
|
</div> |
1089 |
|
|
<a name="methodform" id="form"><!-- --></a> |
1090 |
|
|
<div class="oddrow"> |
1091 |
|
|
|
1092 |
|
|
<div class="method-header"> |
1093 |
|
|
<span class="method-title">form</span> (line <span class="line-number">231</span>) |
1094 |
|
|
</div> |
1095 |
|
|
|
1096 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1097 |
|
|
<p class="short-description">This method builds the html form.</p> |
1098 |
|
|
<p class="description"><p>It is up to the child class to define the layout of the form and return it in a phpHtmllib container.</p></p> |
1099 |
|
|
|
1100 |
|
|
<div class="method-signature"> |
1101 |
|
|
<span class="method-result"><a href="../../phpHtmlLib/Container.html">Container</a></span> |
1102 |
|
|
<span class="method-name"> |
1103 |
|
|
form |
1104 |
|
|
</span> |
1105 |
|
|
() |
1106 |
|
|
</div> |
1107 |
|
|
|
1108 |
|
|
|
1109 |
|
|
|
1110 |
|
|
<hr class="separator" /> |
1111 |
|
|
<div class="notes">Redefined in descendants as:</div> |
1112 |
|
|
<ul class="redefinitions"> |
1113 |
|
|
<li> |
1114 |
|
|
<a href="../../phpHtmlLib/form-examples/AccountForm.html#methodform">AccountForm::form()</a> |
1115 |
|
|
: This is the method that builds the layout of where the FormElements will live. You can lay it out any way you like. |
1116 |
|
|
</li> |
1117 |
|
|
<li> |
1118 |
|
|
<a href="../../phpHtmlLib/FormProcessing/StandardFormContent.html#methodform">StandardFormContent::form()</a> |
1119 |
|
|
: this builds the main wrapper for the form fields and ads the Save and Cancel buttons |
1120 |
|
|
</li> |
1121 |
|
|
</ul> |
1122 |
|
|
</div> |
1123 |
|
|
<a name="methodform_action" id="form_action"><!-- --></a> |
1124 |
|
|
<div class="evenrow"> |
1125 |
|
|
|
1126 |
|
|
<div class="method-header"> |
1127 |
|
|
<span class="method-title">form_action</span> (line <span class="line-number">378</span>) |
1128 |
|
|
</div> |
1129 |
|
|
|
1130 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1131 |
|
|
<p class="short-description">This method handles the</p> |
1132 |
|
|
<p class="description"><p>action (submit button) that was submitted. This method only gets called AFTER all data has been validated. This includes the backend validation. If the form has the confirmation on, then this method will be called after the confirmation has been accepted.</p><p>NOTE : return TRUE if the action was succesfully handled. If FALSE is returned, the form will be displayed again with the error message.</p></p> |
1133 |
|
|
<ul class="tags"> |
1134 |
|
|
<li><span class="field">return:</span> <p>TRUE = success FALSE = failed.</p></li> |
1135 |
|
|
</ul> |
1136 |
|
|
|
1137 |
|
|
<div class="method-signature"> |
1138 |
|
|
<span class="method-result">boolean</span> |
1139 |
|
|
<span class="method-name"> |
1140 |
|
|
form_action |
1141 |
|
|
</span> |
1142 |
|
|
(<span class="var-type">array</span> <span class="var-name">0</span>) |
1143 |
|
|
</div> |
1144 |
|
|
|
1145 |
|
|
<ul class="parameters"> |
1146 |
|
|
<li> |
1147 |
|
|
<span class="var-type">array</span> |
1148 |
|
|
<span class="var-name">0</span><span class="var-description">: <p>- array of errors if any</p></span> </li> |
1149 |
|
|
</ul> |
1150 |
|
|
|
1151 |
|
|
|
1152 |
|
|
<hr class="separator" /> |
1153 |
|
|
<div class="notes">Redefined in descendants as:</div> |
1154 |
|
|
<ul class="redefinitions"> |
1155 |
|
|
<li> |
1156 |
|
|
<a href="../../phpHtmlLib/form-examples/AccountForm.html#methodform_action">AccountForm::form_action()</a> |
1157 |
|
|
: This method is called ONLY after ALL validation has passed. This is the method that allows you to do something with the data, say insert/update records in the DB. |
1158 |
|
|
</li> |
1159 |
|
|
<li> |
1160 |
|
|
<a href="../../phpHtmlLib/FormProcessing/StandardFormContent.html#methodform_action">StandardFormContent::form_action()</a> |
1161 |
|
|
: This method handles the form action. |
1162 |
|
|
</li> |
1163 |
|
|
</ul> |
1164 |
|
|
</div> |
1165 |
|
|
<a name="methodform_backend_validation" id="form_backend_validation"><!-- --></a> |
1166 |
|
|
<div class="oddrow"> |
1167 |
|
|
|
1168 |
|
|
<div class="method-header"> |
1169 |
|
|
<span class="method-title">form_backend_validation</span> (line <span class="line-number">350</span>) |
1170 |
|
|
</div> |
1171 |
|
|
|
1172 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1173 |
|
|
<p class="short-description">This method is called after the FormElements</p> |
1174 |
|
|
<p class="description"><p>have all been validated, and the form_confirm has been confirmed. It enables the form to validate any data against a DB or other backend processing. This will always get called before the form_action method is called to ensure that all form data is valid before form_action() is called.</p></p> |
1175 |
|
|
<ul class="tags"> |
1176 |
|
|
<li><span class="field">return:</span> <p>TRUE if successfull FALSE if errors were detected.</p></li> |
1177 |
|
|
</ul> |
1178 |
|
|
|
1179 |
|
|
<div class="method-signature"> |
1180 |
|
|
<span class="method-result">boolean</span> |
1181 |
|
|
<span class="method-name"> |
1182 |
|
|
form_backend_validation |
1183 |
|
|
</span> |
1184 |
|
|
() |
1185 |
|
|
</div> |
1186 |
|
|
|
1187 |
|
|
|
1188 |
|
|
|
1189 |
|
|
<hr class="separator" /> |
1190 |
|
|
<div class="notes">Redefined in descendants as:</div> |
1191 |
|
|
<ul class="redefinitions"> |
1192 |
|
|
<li> |
1193 |
|
|
<a href="../../phpHtmlLib/form-examples/AccountForm.html#methodform_backend_validation">AccountForm::form_backend_validation()</a> |
1194 |
|
|
: This method gets called after the FormElement data has passed the validation. This enables you to validate the data against some backend mechanism, say a DB. |
1195 |
|
|
</li> |
1196 |
|
|
<li> |
1197 |
|
|
<a href="../../phpHtmlLib/form-examples/Step1.html#methodform_backend_validation">Step1::form_backend_validation()</a> |
1198 |
|
|
: This method gets called after the FormElement data has passed the validation, and has been confirmed. This enables you to validate the data against some backend mechanism, say a DB. |
1199 |
|
|
</li> |
1200 |
|
|
<li> |
1201 |
|
|
<a href="../../phpHtmlLib/form-examples/StandardAccountForm.html#methodform_backend_validation">StandardAccountForm::form_backend_validation()</a> |
1202 |
|
|
: This method gets called after the FormElement data has passed the validation, and has been confirmed. This enables you to validate the data against some backend mechanism, say a DB. |
1203 |
|
|
</li> |
1204 |
|
|
</ul> |
1205 |
|
|
</div> |
1206 |
|
|
<a name="methodform_confirm" id="form_confirm"><!-- --></a> |
1207 |
|
|
<div class="evenrow"> |
1208 |
|
|
|
1209 |
|
|
<div class="method-header"> |
1210 |
|
|
<span class="method-title">form_confirm</span> (line <span class="line-number">279</span>) |
1211 |
|
|
</div> |
1212 |
|
|
|
1213 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1214 |
|
|
<p class="short-description">This function is used to show an intermediary confirmation page. Use this function to show a confirmation of the data that was submitted by the user.</p> |
1215 |
|
|
<p class="description"><p>This will get called after all of the form data was successfully validated. All of the form data will automatically be created as hidden form fields. All you have to do is show the data, and a confirm submit button.</p></p> |
1216 |
|
|
<ul class="tags"> |
1217 |
|
|
<li><span class="field">return:</span> <p>- either raw html, or some container HTMLTag object.</p></li> |
1218 |
|
|
</ul> |
1219 |
|
|
|
1220 |
|
|
<div class="method-signature"> |
1221 |
|
|
<span class="method-result">mixed</span> |
1222 |
|
|
<span class="method-name"> |
1223 |
|
|
form_confirm |
1224 |
|
|
</span> |
1225 |
|
|
([<span class="var-type">string</span> <span class="var-name">$title</span> = <span class="var-default">"Form Confirmation"</span>], [<span class="var-type">boolean</span> <span class="var-name">$show_buttons</span> = <span class="var-default">TRUE</span>]) |
1226 |
|
|
</div> |
1227 |
|
|
|
1228 |
|
|
<ul class="parameters"> |
1229 |
|
|
<li> |
1230 |
|
|
<span class="var-type">string</span> |
1231 |
|
|
<span class="var-name">$title</span><span class="var-description">: <p>- the title for the table</p></span> </li> |
1232 |
|
|
<li> |
1233 |
|
|
<span class="var-type">boolean</span> |
1234 |
|
|
<span class="var-name">$show_buttons</span><span class="var-description">: <p>- show the action buttons?</p></span> </li> |
1235 |
|
|
</ul> |
1236 |
|
|
|
1237 |
|
|
|
1238 |
|
|
<hr class="separator" /> |
1239 |
|
|
<div class="notes">Redefined in descendants as:</div> |
1240 |
|
|
<ul class="redefinitions"> |
1241 |
|
|
<li> |
1242 |
|
|
<a href="../../phpHtmlLib/FormProcessing/StandardFormContent.html#methodform_confirm">StandardFormContent::form_confirm()</a> |
1243 |
|
|
: This function is used to show an intermediary confirmation page. Use this function to show a confirmation of the data that was submitted by the user. |
1244 |
|
|
</li> |
1245 |
|
|
</ul> |
1246 |
|
|
</div> |
1247 |
|
|
<a name="methodform_errors" id="form_errors"><!-- --></a> |
1248 |
|
|
<div class="oddrow"> |
1249 |
|
|
|
1250 |
|
|
<div class="method-header"> |
1251 |
|
|
<span class="method-title">form_errors</span> (line <span class="line-number">405</span>) |
1252 |
|
|
</div> |
1253 |
|
|
|
1254 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1255 |
|
|
<p class="short-description">This function is used to render the error table for the form. The error data comes from the FormProcessor or the FormValidation.</p> |
1256 |
|
|
<p class="description"><p>NOTE: You can override this method to show a customized error message(s)</p></p> |
1257 |
|
|
<ul class="tags"> |
1258 |
|
|
<li><span class="field">return:</span> <p>object.</p></li> |
1259 |
|
|
</ul> |
1260 |
|
|
|
1261 |
|
|
<div class="method-signature"> |
1262 |
|
|
<span class="method-result"><a href="../../phpHtmlLib/TABLEtag.html">TABLEtag</a></span> |
1263 |
|
|
<span class="method-name"> |
1264 |
|
|
form_errors |
1265 |
|
|
</span> |
1266 |
|
|
() |
1267 |
|
|
</div> |
1268 |
|
|
|
1269 |
|
|
|
1270 |
|
|
|
1271 |
|
|
</div> |
1272 |
|
|
<a name="methodform_init_data" id="form_init_data"><!-- --></a> |
1273 |
|
|
<div class="evenrow"> |
1274 |
|
|
|
1275 |
|
|
<div class="method-header"> |
1276 |
|
|
<span class="method-title">form_init_data</span> (line <span class="line-number">218</span>) |
1277 |
|
|
</div> |
1278 |
|
|
|
1279 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1280 |
|
|
<p class="short-description">This method is called by the</p> |
1281 |
|
|
<p class="description"><p>Form Processor to allow this class to do any fetching of data to prepopulate the form field values. You typically use this to read data from a DB.</p><p>This method is only called once when the form is first hit.</p><p>NOTE: you should build the data and save it in $this->_init_data</p></p> |
1282 |
|
|
|
1283 |
|
|
<div class="method-signature"> |
1284 |
|
|
<span class="method-result">void</span> |
1285 |
|
|
<span class="method-name"> |
1286 |
|
|
form_init_data |
1287 |
|
|
</span> |
1288 |
|
|
() |
1289 |
|
|
</div> |
1290 |
|
|
|
1291 |
|
|
|
1292 |
|
|
|
1293 |
|
|
<hr class="separator" /> |
1294 |
|
|
<div class="notes">Redefined in descendants as:</div> |
1295 |
|
|
<ul class="redefinitions"> |
1296 |
|
|
<li> |
1297 |
|
|
<a href="../../phpHtmlLib/form-examples/AccountForm.html#methodform_init_data">AccountForm::form_init_data()</a> |
1298 |
|
|
: This method is called only the first time the form page is hit. This enables u to query a DB and pre populate the FormElement objects with data. |
1299 |
|
|
</li> |
1300 |
|
|
<li> |
1301 |
|
|
<a href="../../phpHtmlLib/form-examples/Step1.html#methodform_init_data">Step1::form_init_data()</a> |
1302 |
|
|
: This method is called only the first time the form page is hit. |
1303 |
|
|
</li> |
1304 |
|
|
<li> |
1305 |
|
|
<a href="../../phpHtmlLib/form-examples/Step2.html#methodform_init_data">Step2::form_init_data()</a> |
1306 |
|
|
: This method is called only the first time the form page is hit. |
1307 |
|
|
</li> |
1308 |
|
|
<li> |
1309 |
|
|
<a href="../../phpHtmlLib/form-examples/Step3.html#methodform_init_data">Step3::form_init_data()</a> |
1310 |
|
|
: This method is called only the first time the form page is hit. |
1311 |
|
|
</li> |
1312 |
|
|
<li> |
1313 |
|
|
<a href="../../phpHtmlLib/form-examples/StandardAccountForm.html#methodform_init_data">StandardAccountForm::form_init_data()</a> |
1314 |
|
|
: This method is called only the first time the form page is hit. |
1315 |
|
|
</li> |
1316 |
|
|
</ul> |
1317 |
|
|
</div> |
1318 |
|
|
<a name="methodform_init_elements" id="form_init_elements"><!-- --></a> |
1319 |
|
|
<div class="oddrow"> |
1320 |
|
|
|
1321 |
|
|
<div class="method-header"> |
1322 |
|
|
<span class="method-title">form_init_elements</span> (line <span class="line-number">198</span>) |
1323 |
|
|
</div> |
1324 |
|
|
|
1325 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1326 |
|
|
<p class="short-description">This method is what is called to build the list of FormElements that will be used by this form.</p> |
1327 |
|
|
|
1328 |
|
|
<div class="method-signature"> |
1329 |
|
|
<span class="method-result">void</span> |
1330 |
|
|
<span class="method-name"> |
1331 |
|
|
form_init_elements |
1332 |
|
|
</span> |
1333 |
|
|
() |
1334 |
|
|
</div> |
1335 |
|
|
|
1336 |
|
|
|
1337 |
|
|
|
1338 |
|
|
<hr class="separator" /> |
1339 |
|
|
<div class="notes">Redefined in descendants as:</div> |
1340 |
|
|
<ul class="redefinitions"> |
1341 |
|
|
<li> |
1342 |
|
|
<a href="../../phpHtmlLib/form-examples/AccountForm.html#methodform_init_elements">AccountForm::form_init_elements()</a> |
1343 |
|
|
: This method gets called EVERY time the object is created. It is used to build all of the FormElement objects used in this Form. |
1344 |
|
|
</li> |
1345 |
|
|
<li> |
1346 |
|
|
<a href="../../phpHtmlLib/form-examples/Step1.html#methodform_init_elements">Step1::form_init_elements()</a> |
1347 |
|
|
: This method gets called EVERY time the object is |
1348 |
|
|
</li> |
1349 |
|
|
<li> |
1350 |
|
|
<a href="../../phpHtmlLib/form-examples/Step2.html#methodform_init_elements">Step2::form_init_elements()</a> |
1351 |
|
|
: This method gets called EVERY time the object is |
1352 |
|
|
</li> |
1353 |
|
|
<li> |
1354 |
|
|
<a href="../../phpHtmlLib/form-examples/Step3.html#methodform_init_elements">Step3::form_init_elements()</a> |
1355 |
|
|
: This method gets called EVERY time the object is |
1356 |
|
|
</li> |
1357 |
|
|
<li> |
1358 |
|
|
<a href="../../phpHtmlLib/form-examples/StandardAccountForm.html#methodform_init_elements">StandardAccountForm::form_init_elements()</a> |
1359 |
|
|
: This method gets called EVERY time the object is |
1360 |
|
|
</li> |
1361 |
|
|
</ul> |
1362 |
|
|
</div> |
1363 |
|
|
<a name="methodform_success" id="form_success"><!-- --></a> |
1364 |
|
|
<div class="evenrow"> |
1365 |
|
|
|
1366 |
|
|
<div class="method-header"> |
1367 |
|
|
<span class="method-title">form_success</span> (line <span class="line-number">392</span>) |
1368 |
|
|
</div> |
1369 |
|
|
|
1370 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1371 |
|
|
<p class="short-description">This method is called when the form_action() was successfull, and the form wants to render some kind of message</p> |
1372 |
|
|
|
1373 |
|
|
<div class="method-signature"> |
1374 |
|
|
<span class="method-result">mixed</span> |
1375 |
|
|
<span class="method-name"> |
1376 |
|
|
form_success |
1377 |
|
|
</span> |
1378 |
|
|
() |
1379 |
|
|
</div> |
1380 |
|
|
|
1381 |
|
|
|
1382 |
|
|
|
1383 |
|
|
</div> |
1384 |
|
|
<a name="methodget_action" id="get_action"><!-- --></a> |
1385 |
|
|
<div class="oddrow"> |
1386 |
|
|
|
1387 |
|
|
<div class="method-header"> |
1388 |
|
|
<span class="method-title">get_action</span> (line <span class="line-number">622</span>) |
1389 |
|
|
</div> |
1390 |
|
|
|
1391 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1392 |
|
|
<p class="short-description">Get the current status of the action.</p> |
1393 |
|
|
|
1394 |
|
|
<div class="method-signature"> |
1395 |
|
|
<span class="method-result">string</span> |
1396 |
|
|
<span class="method-name"> |
1397 |
|
|
get_action |
1398 |
|
|
</span> |
1399 |
|
|
() |
1400 |
|
|
</div> |
1401 |
|
|
|
1402 |
|
|
|
1403 |
|
|
|
1404 |
|
|
</div> |
1405 |
|
|
<a name="methodget_default_css" id="get_default_css"><!-- --></a> |
1406 |
|
|
<div class="evenrow"> |
1407 |
|
|
|
1408 |
|
|
<div class="method-header"> |
1409 |
|
|
<span class="method-title">get_default_css</span> (line <span class="line-number">697</span>) |
1410 |
|
|
</div> |
1411 |
|
|
|
1412 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1413 |
|
|
<p class="short-description">This function returns the default css class used for NON error text.</p> |
1414 |
|
|
<ul class="tags"> |
1415 |
|
|
<li><span class="field">return:</span> <p>- the current default css</p></li> |
1416 |
|
|
</ul> |
1417 |
|
|
|
1418 |
|
|
<div class="method-signature"> |
1419 |
|
|
<span class="method-result">string</span> |
1420 |
|
|
<span class="method-name"> |
1421 |
|
|
get_default_css |
1422 |
|
|
</span> |
1423 |
|
|
() |
1424 |
|
|
</div> |
1425 |
|
|
|
1426 |
|
|
|
1427 |
|
|
|
1428 |
|
|
</div> |
1429 |
|
|
<a name="methodget_element" id="get_element"><!-- --></a> |
1430 |
|
|
<div class="oddrow"> |
1431 |
|
|
|
1432 |
|
|
<div class="method-header"> |
1433 |
|
|
<span class="method-title">get_element</span> (line <span class="line-number">524</span>) |
1434 |
|
|
</div> |
1435 |
|
|
|
1436 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1437 |
|
|
<p class="short-description">This method returns the FormElement based on the label.</p> |
1438 |
|
|
|
1439 |
|
|
<div class="method-signature"> |
1440 |
|
|
<span class="method-result">Object</span> |
1441 |
|
|
<span class="method-name"> |
1442 |
|
|
&get_element |
1443 |
|
|
</span> |
1444 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>) |
1445 |
|
|
</div> |
1446 |
|
|
|
1447 |
|
|
<ul class="parameters"> |
1448 |
|
|
<li> |
1449 |
|
|
<span class="var-type">string</span> |
1450 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>- the element's label</p></span> </li> |
1451 |
|
|
</ul> |
1452 |
|
|
|
1453 |
|
|
|
1454 |
jonen |
1.1 |
</div> |
1455 |
jonen |
1.2 |
<a name="methodget_element_value" id="get_element_value"><!-- --></a> |
1456 |
|
|
<div class="evenrow"> |
1457 |
|
|
|
1458 |
|
|
<div class="method-header"> |
1459 |
|
|
<span class="method-title">get_element_value</span> (line <span class="line-number">550</span>) |
1460 |
|
|
</div> |
1461 |
|
|
|
1462 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1463 |
|
|
<p class="short-description">This method is used to get the value for a non hidden element</p> |
1464 |
|
|
<ul class="tags"> |
1465 |
|
|
<li><span class="field">return:</span> <p>- the new value</p></li> |
1466 |
|
|
</ul> |
1467 |
|
|
|
1468 |
|
|
<div class="method-signature"> |
1469 |
|
|
<span class="method-result">value</span> |
1470 |
|
|
<span class="method-name"> |
1471 |
|
|
get_element_value |
1472 |
|
|
</span> |
1473 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>) |
1474 |
|
|
</div> |
1475 |
|
|
|
1476 |
|
|
<ul class="parameters"> |
1477 |
|
|
<li> |
1478 |
|
|
<span class="var-type">string</span> |
1479 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>- the form label</p></span> </li> |
1480 |
|
|
</ul> |
1481 |
|
|
|
1482 |
|
|
|
1483 |
|
|
</div> |
1484 |
|
|
<a name="methodget_error_array" id="get_error_array"><!-- --></a> |
1485 |
|
|
<div class="oddrow"> |
1486 |
|
|
|
1487 |
|
|
<div class="method-header"> |
1488 |
|
|
<span class="method-title">get_error_array</span> (line <span class="line-number">436</span>) |
1489 |
|
|
</div> |
1490 |
|
|
|
1491 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1492 |
|
|
<p class="short-description">This method returns an array of errors for all the errors.</p> |
1493 |
|
|
|
1494 |
|
|
<div class="method-signature"> |
1495 |
|
|
<span class="method-result">array</span> |
1496 |
|
|
<span class="method-name"> |
1497 |
|
|
get_error_array |
1498 |
|
|
</span> |
1499 |
|
|
() |
1500 |
|
|
</div> |
1501 |
|
|
|
1502 |
|
|
|
1503 |
|
|
|
1504 |
|
|
</div> |
1505 |
|
|
<a name="methodget_form_errors_width" id="get_form_errors_width"><!-- --></a> |
1506 |
|
|
<div class="evenrow"> |
1507 |
|
|
|
1508 |
|
|
<div class="method-header"> |
1509 |
|
|
<span class="method-title">get_form_errors_width</span> (line <span class="line-number">644</span>) |
1510 |
|
|
</div> |
1511 |
|
|
|
1512 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1513 |
|
|
<p class="short-description">This method returns the width of the form errors table.</p> |
1514 |
|
|
<p class="description"><p>By default it is supposed to be the same width as the form itself.</p></p> |
1515 |
|
|
|
1516 |
|
|
<div class="method-signature"> |
1517 |
|
|
<span class="method-result">int</span> |
1518 |
|
|
<span class="method-name"> |
1519 |
|
|
get_form_errors_width |
1520 |
|
|
</span> |
1521 |
|
|
() |
1522 |
|
|
</div> |
1523 |
|
|
|
1524 |
|
|
|
1525 |
|
|
|
1526 |
|
|
</div> |
1527 |
|
|
<a name="methodget_hidden_element_value" id="get_hidden_element_value"><!-- --></a> |
1528 |
|
|
<div class="oddrow"> |
1529 |
|
|
|
1530 |
|
|
<div class="method-header"> |
1531 |
|
|
<span class="method-title">get_hidden_element_value</span> (line <span class="line-number">574</span>) |
1532 |
|
|
</div> |
1533 |
|
|
|
1534 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1535 |
|
|
<p class="short-description">This method is used to get the value for a hidden element</p> |
1536 |
|
|
<ul class="tags"> |
1537 |
|
|
<li><span class="field">return:</span> <p>- the new value</p></li> |
1538 |
|
|
</ul> |
1539 |
|
|
|
1540 |
|
|
<div class="method-signature"> |
1541 |
|
|
<span class="method-result">value</span> |
1542 |
|
|
<span class="method-name"> |
1543 |
|
|
get_hidden_element_value |
1544 |
|
|
</span> |
1545 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>) |
1546 |
|
|
</div> |
1547 |
|
|
|
1548 |
|
|
<ul class="parameters"> |
1549 |
|
|
<li> |
1550 |
|
|
<span class="var-type">string</span> |
1551 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>- the form label</p></span> </li> |
1552 |
|
|
</ul> |
1553 |
|
|
|
1554 |
|
|
|
1555 |
|
|
</div> |
1556 |
|
|
<a name="methodget_required_fields_text" id="get_required_fields_text"><!-- --></a> |
1557 |
|
|
<div class="evenrow"> |
1558 |
|
|
|
1559 |
|
|
<div class="method-header"> |
1560 |
|
|
<span class="method-title">get_required_fields_text</span> (line <span class="line-number">932</span>) |
1561 |
|
|
</div> |
1562 |
|
|
|
1563 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1564 |
|
|
<p class="short-description">This returns the required field text</p> |
1565 |
|
|
<p class="description"><p>if there are any. otherwise it returns NULL</p></p> |
1566 |
|
|
|
1567 |
|
|
<div class="method-signature"> |
1568 |
|
|
<span class="method-result">void</span> |
1569 |
|
|
<span class="method-name"> |
1570 |
|
|
get_required_fields_text |
1571 |
|
|
</span> |
1572 |
|
|
() |
1573 |
|
|
</div> |
1574 |
|
|
|
1575 |
|
|
|
1576 |
|
|
|
1577 |
|
|
</div> |
1578 |
|
|
<a name="methodhas_confirm" id="has_confirm"><!-- --></a> |
1579 |
|
|
<div class="oddrow"> |
1580 |
|
|
|
1581 |
|
|
<div class="method-header"> |
1582 |
|
|
<span class="method-title">has_confirm</span> (line <span class="line-number">737</span>) |
1583 |
|
|
</div> |
1584 |
|
|
|
1585 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1586 |
|
|
<p class="short-description">This gets the value of the confirmation flag.</p> |
1587 |
|
|
<p class="description"><p>which tells the caller that this object has/doesn't have a required confirmation page.</p></p> |
1588 |
|
|
|
1589 |
|
|
<div class="method-signature"> |
1590 |
|
|
<span class="method-result">boolean</span> |
1591 |
|
|
<span class="method-name"> |
1592 |
|
|
has_confirm |
1593 |
|
|
</span> |
1594 |
|
|
() |
1595 |
|
|
</div> |
1596 |
|
|
|
1597 |
|
|
|
1598 |
|
|
|
1599 |
|
|
</div> |
1600 |
|
|
<a name="methodhidden_element_label" id="hidden_element_label"><!-- --></a> |
1601 |
|
|
<div class="evenrow"> |
1602 |
|
|
|
1603 |
|
|
<div class="method-header"> |
1604 |
|
|
<span class="method-title">hidden_element_label</span> (line <span class="line-number">499</span>) |
1605 |
|
|
</div> |
1606 |
|
|
|
1607 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1608 |
|
|
<p class="short-description">This method returns the label object for a visible form element.</p> |
1609 |
|
|
|
1610 |
|
|
<div class="method-signature"> |
1611 |
|
|
<span class="method-result">Object</span> |
1612 |
|
|
<span class="method-name"> |
1613 |
|
|
hidden_element_label |
1614 |
|
|
</span> |
1615 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>) |
1616 |
|
|
</div> |
1617 |
|
|
|
1618 |
|
|
<ul class="parameters"> |
1619 |
|
|
<li> |
1620 |
|
|
<span class="var-type">string</span> |
1621 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>- the element's label</p></span> </li> |
1622 |
|
|
</ul> |
1623 |
|
|
|
1624 |
|
|
|
1625 |
|
|
</div> |
1626 |
|
|
<a name="methodjavascript" id="javascript"><!-- --></a> |
1627 |
|
|
<div class="oddrow"> |
1628 |
|
|
|
1629 |
|
|
<div class="method-header"> |
1630 |
|
|
<span class="method-title">javascript</span> (line <span class="line-number">244</span>) |
1631 |
|
|
</div> |
1632 |
|
|
|
1633 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1634 |
|
|
<p class="short-description">This method lets you provide any javascript that is associated with the form content.</p> |
1635 |
|
|
<p class="description"><p>The FormProcessor will automatically call this and wrap it in a script tag.</p></p> |
1636 |
|
|
<ul class="tags"> |
1637 |
|
|
<li><span class="field">return:</span> <p>- raw js.</p></li> |
1638 |
|
|
</ul> |
1639 |
|
|
|
1640 |
|
|
<div class="method-signature"> |
1641 |
|
|
<span class="method-result">string</span> |
1642 |
|
|
<span class="method-name"> |
1643 |
|
|
javascript |
1644 |
|
|
</span> |
1645 |
|
|
() |
1646 |
|
|
</div> |
1647 |
|
|
|
1648 |
|
|
|
1649 |
|
|
|
1650 |
|
|
</div> |
1651 |
|
|
<a name="methodpre_confirm" id="pre_confirm"><!-- --></a> |
1652 |
|
|
<div class="evenrow"> |
1653 |
|
|
|
1654 |
|
|
<div class="method-header"> |
1655 |
|
|
<span class="method-title">pre_confirm</span> (line <span class="line-number">256</span>) |
1656 |
|
|
</div> |
1657 |
|
|
|
1658 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1659 |
|
|
<p class="short-description">This method allows this class to do any data munging prior to the form_confirm method being called @ render time.</p> |
1660 |
|
|
<ul class="tags"> |
1661 |
|
|
<li><span class="field">return:</span> <p>= success FALSE if u want to trigger an error</p></li> |
1662 |
|
|
</ul> |
1663 |
|
|
|
1664 |
|
|
<div class="method-signature"> |
1665 |
|
|
<span class="method-result">TRUE</span> |
1666 |
|
|
<span class="method-name"> |
1667 |
|
|
pre_confirm |
1668 |
|
|
</span> |
1669 |
|
|
() |
1670 |
|
|
</div> |
1671 |
|
|
|
1672 |
|
|
|
1673 |
|
|
|
1674 |
|
|
</div> |
1675 |
|
|
<a name="methodset_action" id="set_action"><!-- --></a> |
1676 |
|
|
<div class="oddrow"> |
1677 |
|
|
|
1678 |
|
|
<div class="method-header"> |
1679 |
|
|
<span class="method-title">set_action</span> (line <span class="line-number">612</span>) |
1680 |
|
|
</div> |
1681 |
|
|
|
1682 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1683 |
|
|
<p class="short-description">Save the action for the form</p> |
1684 |
|
|
|
1685 |
|
|
<div class="method-signature"> |
1686 |
|
|
<span class="method-result">void</span> |
1687 |
|
|
<span class="method-name"> |
1688 |
|
|
set_action |
1689 |
|
|
</span> |
1690 |
|
|
(<span class="var-type">string</span> <span class="var-name">$action</span>) |
1691 |
|
|
</div> |
1692 |
|
|
|
1693 |
|
|
<ul class="parameters"> |
1694 |
|
|
<li> |
1695 |
|
|
<span class="var-type">string</span> |
1696 |
|
|
<span class="var-name">$action</span><span class="var-description">: <p>- the action from the post.</p></span> </li> |
1697 |
|
|
</ul> |
1698 |
|
|
|
1699 |
|
|
|
1700 |
|
|
</div> |
1701 |
|
|
<a name="methodset_action_message" id="set_action_message"><!-- --></a> |
1702 |
|
|
<div class="evenrow"> |
1703 |
|
|
|
1704 |
|
|
<div class="method-header"> |
1705 |
|
|
<span class="method-title">set_action_message</span> (line <span class="line-number">759</span>) |
1706 |
|
|
</div> |
1707 |
|
|
|
1708 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1709 |
|
|
<p class="short-description">This sets the action message.</p> |
1710 |
|
|
<p class="description"><p>This is called from withint the form_action() method</p></p> |
1711 |
|
|
|
1712 |
|
|
<div class="method-signature"> |
1713 |
|
|
<span class="method-result">void</span> |
1714 |
|
|
<span class="method-name"> |
1715 |
|
|
set_action_message |
1716 |
|
|
</span> |
1717 |
|
|
(<span class="var-type">string</span> <span class="var-name">$message</span>) |
1718 |
|
|
</div> |
1719 |
|
|
|
1720 |
|
|
<ul class="parameters"> |
1721 |
|
|
<li> |
1722 |
|
|
<span class="var-type">string</span> |
1723 |
|
|
<span class="var-name">$message</span><span class="var-description">: <p>- the action message</p></span> </li> |
1724 |
|
|
</ul> |
1725 |
|
|
|
1726 |
|
|
|
1727 |
|
|
</div> |
1728 |
|
|
<a name="methodset_cancel_action" id="set_cancel_action"><!-- --></a> |
1729 |
|
|
<div class="oddrow"> |
1730 |
|
|
|
1731 |
|
|
<div class="method-header"> |
1732 |
|
|
<span class="method-title">set_cancel_action</span> (line <span class="line-number">773</span>) |
1733 |
|
|
</div> |
1734 |
|
|
|
1735 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1736 |
|
|
<p class="short-description">This method sets the javasript action</p> |
1737 |
|
|
<p class="description"><p>to be taken when the cancel button is clicked. Calling this method w/ a non NULL value automatically enables the Cancel button.</p></p> |
1738 |
|
|
|
1739 |
|
|
<div class="method-signature"> |
1740 |
|
|
<span class="method-result">void</span> |
1741 |
|
|
<span class="method-name"> |
1742 |
|
|
set_cancel_action |
1743 |
|
|
</span> |
1744 |
|
|
(<span class="var-type">string</span> <span class="var-name">$action</span>) |
1745 |
|
|
</div> |
1746 |
|
|
|
1747 |
|
|
<ul class="parameters"> |
1748 |
|
|
<li> |
1749 |
|
|
<span class="var-type">string</span> |
1750 |
|
|
<span class="var-name">$action</span><span class="var-description">: <p>- the javascript cancel action</p></span> </li> |
1751 |
|
|
</ul> |
1752 |
|
|
|
1753 |
|
|
|
1754 |
|
|
</div> |
1755 |
|
|
<a name="methodset_confirm" id="set_confirm"><!-- --></a> |
1756 |
|
|
<div class="evenrow"> |
1757 |
|
|
|
1758 |
|
|
<div class="method-header"> |
1759 |
|
|
<span class="method-title">set_confirm</span> (line <span class="line-number">725</span>) |
1760 |
|
|
</div> |
1761 |
|
|
|
1762 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1763 |
|
|
<p class="short-description">This sets the $this->_has_confirmation</p> |
1764 |
|
|
<p class="description"><p>flag. to let the object know it has a required confirmation page, which should get called after the validation is successfull, and before the action is handled on the back-end.</p></p> |
1765 |
|
|
|
1766 |
|
|
<div class="method-signature"> |
1767 |
|
|
<span class="method-result">void</span> |
1768 |
|
|
<span class="method-name"> |
1769 |
|
|
set_confirm |
1770 |
|
|
</span> |
1771 |
|
|
([<span class="var-type">boolean</span> <span class="var-name">$flag</span> = <span class="var-default">TRUE</span>]) |
1772 |
|
|
</div> |
1773 |
|
|
|
1774 |
|
|
<ul class="parameters"> |
1775 |
|
|
<li> |
1776 |
|
|
<span class="var-type">boolean</span> |
1777 |
|
|
<span class="var-name">$flag</span><span class="var-description">: <p>- the flag value TRUE/FALSE</p></span> </li> |
1778 |
|
|
</ul> |
1779 |
|
|
|
1780 |
|
|
|
1781 |
|
|
</div> |
1782 |
|
|
<a name="methodset_default_css" id="set_default_css"><!-- --></a> |
1783 |
|
|
<div class="oddrow"> |
1784 |
|
|
|
1785 |
|
|
<div class="method-header"> |
1786 |
|
|
<span class="method-title">set_default_css</span> (line <span class="line-number">686</span>) |
1787 |
|
|
</div> |
1788 |
|
|
|
1789 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1790 |
|
|
<p class="short-description">This function is used to set the</p> |
1791 |
|
|
<p class="description"><p>default CSS class used on form field text when there is no error on that field</p></p> |
1792 |
|
|
|
1793 |
|
|
<div class="method-signature"> |
1794 |
|
|
<span class="method-result">void</span> |
1795 |
|
|
<span class="method-name"> |
1796 |
|
|
set_default_css |
1797 |
|
|
</span> |
1798 |
|
|
(<span class="var-type">string</span> <span class="var-name">$css</span>) |
1799 |
|
|
</div> |
1800 |
|
|
|
1801 |
|
|
<ul class="parameters"> |
1802 |
|
|
<li> |
1803 |
|
|
<span class="var-type">string</span> |
1804 |
|
|
<span class="var-name">$css</span><span class="var-description">: <p>- the css class to use</p></span> </li> |
1805 |
|
|
</ul> |
1806 |
|
|
|
1807 |
|
|
|
1808 |
|
|
</div> |
1809 |
|
|
<a name="methodset_element_value" id="set_element_value"><!-- --></a> |
1810 |
|
|
<div class="evenrow"> |
1811 |
|
|
|
1812 |
|
|
<div class="method-header"> |
1813 |
|
|
<span class="method-title">set_element_value</span> (line <span class="line-number">537</span>) |
1814 |
|
|
</div> |
1815 |
|
|
|
1816 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1817 |
|
|
<p class="short-description">This method is used to set the value for a non hidden element</p> |
1818 |
|
|
|
1819 |
|
|
<div class="method-signature"> |
1820 |
|
|
<span class="method-result">void</span> |
1821 |
|
|
<span class="method-name"> |
1822 |
|
|
set_element_value |
1823 |
|
|
</span> |
1824 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>, <span class="var-type">value</span> <span class="var-name">$value</span>) |
1825 |
|
|
</div> |
1826 |
|
|
|
1827 |
|
|
<ul class="parameters"> |
1828 |
|
|
<li> |
1829 |
|
|
<span class="var-type">string</span> |
1830 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>- the form label</p></span> </li> |
1831 |
|
|
<li> |
1832 |
|
|
<span class="var-type">value</span> |
1833 |
|
|
<span class="var-name">$value</span><span class="var-description">: <p>- the new value</p></span> </li> |
1834 |
|
|
</ul> |
1835 |
|
|
|
1836 |
|
|
|
1837 |
|
|
</div> |
1838 |
|
|
<a name="methodset_error_css" id="set_error_css"><!-- --></a> |
1839 |
|
|
<div class="oddrow"> |
1840 |
|
|
|
1841 |
|
|
<div class="method-header"> |
1842 |
|
|
<span class="method-title">set_error_css</span> (line <span class="line-number">710</span>) |
1843 |
|
|
</div> |
1844 |
|
|
|
1845 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1846 |
|
|
<p class="short-description">This function is used to set the css class that is used on text when an error on that field is detected.</p> |
1847 |
|
|
|
1848 |
|
|
<div class="method-signature"> |
1849 |
|
|
<span class="method-result">void</span> |
1850 |
|
|
<span class="method-name"> |
1851 |
|
|
set_error_css |
1852 |
|
|
</span> |
1853 |
|
|
(<span class="var-type">string</span> <span class="var-name">$css</span>) |
1854 |
|
|
</div> |
1855 |
|
|
|
1856 |
|
|
<ul class="parameters"> |
1857 |
|
|
<li> |
1858 |
|
|
<span class="var-type">string</span> |
1859 |
|
|
<span class="var-name">$css</span><span class="var-description">: <p>- the css class to use.</p></span> </li> |
1860 |
|
|
</ul> |
1861 |
|
|
|
1862 |
|
|
|
1863 |
|
|
</div> |
1864 |
|
|
<a name="methodset_form_errors_title" id="set_form_errors_title"><!-- --></a> |
1865 |
|
|
<div class="evenrow"> |
1866 |
|
|
|
1867 |
|
|
<div class="method-header"> |
1868 |
|
|
<span class="method-title">set_form_errors_title</span> (line <span class="line-number">671</span>) |
1869 |
|
|
</div> |
1870 |
|
|
|
1871 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1872 |
|
|
<p class="short-description">This allows us to change the form errors table title</p> |
1873 |
|
|
|
1874 |
|
|
<div class="method-signature"> |
1875 |
|
|
<span class="method-result">void</span> |
1876 |
|
|
<span class="method-name"> |
1877 |
|
|
set_form_errors_title |
1878 |
|
|
</span> |
1879 |
|
|
(<span class="var-type">string</span> <span class="var-name">$title</span>) |
1880 |
|
|
</div> |
1881 |
|
|
|
1882 |
|
|
<ul class="parameters"> |
1883 |
|
|
<li> |
1884 |
|
|
<span class="var-type">string</span> |
1885 |
|
|
<span class="var-name">$title</span><span class="var-description">: <p>- the new title</p></span> </li> |
1886 |
|
|
</ul> |
1887 |
|
|
|
1888 |
|
|
|
1889 |
|
|
</div> |
1890 |
|
|
<a name="methodset_form_errors_width" id="set_form_errors_width"><!-- --></a> |
1891 |
|
|
<div class="oddrow"> |
1892 |
|
|
|
1893 |
|
|
<div class="method-header"> |
1894 |
|
|
<span class="method-title">set_form_errors_width</span> (line <span class="line-number">660</span>) |
1895 |
|
|
</div> |
1896 |
|
|
|
1897 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1898 |
|
|
<p class="short-description">This method allows you to override the width of the form errors table.</p> |
1899 |
|
|
<p class="description"><p>By default it uses the width of the form as its size.</p></p> |
1900 |
|
|
|
1901 |
|
|
<div class="method-signature"> |
1902 |
|
|
<span class="method-result">void</span> |
1903 |
|
|
<span class="method-name"> |
1904 |
|
|
set_form_errors_width |
1905 |
|
|
</span> |
1906 |
|
|
(<span class="var-type">string</span> <span class="var-name">$width</span>) |
1907 |
|
|
</div> |
1908 |
|
|
|
1909 |
|
|
<ul class="parameters"> |
1910 |
|
|
<li> |
1911 |
|
|
<span class="var-type">string</span> |
1912 |
|
|
<span class="var-name">$width</span><span class="var-description">: <p>- the width</p></span> </li> |
1913 |
|
|
</ul> |
1914 |
|
|
|
1915 |
|
|
|
1916 |
|
|
</div> |
1917 |
|
|
<a name="methodset_form_name" id="set_form_name"><!-- --></a> |
1918 |
|
|
<div class="evenrow"> |
1919 |
|
|
|
1920 |
|
|
<div class="method-header"> |
1921 |
|
|
<span class="method-title">set_form_name</span> (line <span class="line-number">602</span>) |
1922 |
|
|
</div> |
1923 |
|
|
|
1924 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1925 |
|
|
<p class="short-description">**************************</p> |
1926 |
|
|
|
1927 |
|
|
<div class="method-signature"> |
1928 |
|
|
<span class="method-result">void</span> |
1929 |
|
|
<span class="method-name"> |
1930 |
|
|
set_form_name |
1931 |
|
|
</span> |
1932 |
|
|
(<span class="var-type">mixed</span> <span class="var-name">$name</span>) |
1933 |
|
|
</div> |
1934 |
|
|
|
1935 |
|
|
|
1936 |
|
|
|
1937 |
|
|
</div> |
1938 |
|
|
<a name="methodset_form_width" id="set_form_width"><!-- --></a> |
1939 |
|
|
<div class="oddrow"> |
1940 |
|
|
|
1941 |
|
|
<div class="method-header"> |
1942 |
|
|
<span class="method-title">set_form_width</span> (line <span class="line-number">631</span>) |
1943 |
|
|
</div> |
1944 |
|
|
|
1945 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1946 |
|
|
<p class="short-description">this method sets the form name</p> |
1947 |
|
|
|
1948 |
|
|
<div class="method-signature"> |
1949 |
|
|
<span class="method-result">void</span> |
1950 |
|
|
<span class="method-name"> |
1951 |
|
|
set_form_width |
1952 |
|
|
</span> |
1953 |
|
|
(<span class="var-type">string</span> <span class="var-name">$width</span>) |
1954 |
|
|
</div> |
1955 |
|
|
|
1956 |
|
|
<ul class="parameters"> |
1957 |
|
|
<li> |
1958 |
|
|
<span class="var-type">string</span> |
1959 |
|
|
<span class="var-name">$width</span><span class="var-description">: <p>- the form name</p></span> </li> |
1960 |
|
|
</ul> |
1961 |
|
|
|
1962 |
|
|
|
1963 |
|
|
</div> |
1964 |
|
|
<a name="methodset_hidden_element_value" id="set_hidden_element_value"><!-- --></a> |
1965 |
|
|
<div class="evenrow"> |
1966 |
|
|
|
1967 |
|
|
<div class="method-header"> |
1968 |
|
|
<span class="method-title">set_hidden_element_value</span> (line <span class="line-number">562</span>) |
1969 |
|
|
</div> |
1970 |
|
|
|
1971 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
1972 |
|
|
<p class="short-description">This method is used to set the value for a hidden element</p> |
1973 |
|
|
|
1974 |
|
|
<div class="method-signature"> |
1975 |
|
|
<span class="method-result">void</span> |
1976 |
|
|
<span class="method-name"> |
1977 |
|
|
set_hidden_element_value |
1978 |
|
|
</span> |
1979 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>, <span class="var-type">value</span> <span class="var-name">$value</span>) |
1980 |
|
|
</div> |
1981 |
|
|
|
1982 |
|
|
<ul class="parameters"> |
1983 |
|
|
<li> |
1984 |
|
|
<span class="var-type">string</span> |
1985 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>- the form label</p></span> </li> |
1986 |
|
|
<li> |
1987 |
|
|
<span class="var-type">value</span> |
1988 |
|
|
<span class="var-name">$value</span><span class="var-description">: <p>- the new value</p></span> </li> |
1989 |
|
|
</ul> |
1990 |
|
|
|
1991 |
|
|
|
1992 |
|
|
</div> |
1993 |
|
|
<a name="methodset_required_marker" id="set_required_marker"><!-- --></a> |
1994 |
|
|
<div class="oddrow"> |
1995 |
|
|
|
1996 |
|
|
<div class="method-header"> |
1997 |
|
|
<span class="method-title">set_required_marker</span> (line <span class="line-number">950</span>) |
1998 |
|
|
</div> |
1999 |
|
|
|
2000 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
2001 |
|
|
<p class="short-description">This function is used to set the required field marker</p> |
2002 |
|
|
|
2003 |
|
|
<div class="method-signature"> |
2004 |
|
|
<span class="method-result">void</span> |
2005 |
|
|
<span class="method-name"> |
2006 |
|
|
set_required_marker |
2007 |
|
|
</span> |
2008 |
|
|
(<span class="var-type">string</span> <span class="var-name">$marker</span>) |
2009 |
|
|
</div> |
2010 |
|
|
|
2011 |
|
|
<ul class="parameters"> |
2012 |
|
|
<li> |
2013 |
|
|
<span class="var-type">string</span> |
2014 |
|
|
<span class="var-name">$marker</span><span class="var-description">: <p>- the marker</p></span> </li> |
2015 |
|
|
</ul> |
2016 |
|
|
|
2017 |
|
|
|
2018 |
|
|
</div> |
2019 |
|
|
<a name="methodset_required_text" id="set_required_text"><!-- --></a> |
2020 |
|
|
<div class="evenrow"> |
2021 |
|
|
|
2022 |
|
|
<div class="method-header"> |
2023 |
|
|
<span class="method-title">set_required_text</span> (line <span class="line-number">959</span>) |
2024 |
|
|
</div> |
2025 |
|
|
|
2026 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
2027 |
|
|
<p class="short-description">This sets the required text</p> |
2028 |
|
|
|
2029 |
|
|
<div class="method-signature"> |
2030 |
|
|
<span class="method-result">void</span> |
2031 |
|
|
<span class="method-name"> |
2032 |
|
|
set_required_text |
2033 |
|
|
</span> |
2034 |
|
|
(<span class="var-type">string</span> <span class="var-name">$text</span>) |
2035 |
|
|
</div> |
2036 |
|
|
|
2037 |
|
|
<ul class="parameters"> |
2038 |
|
|
<li> |
2039 |
|
|
<span class="var-type">string</span> |
2040 |
|
|
<span class="var-name">$text</span> </li> |
2041 |
|
|
</ul> |
2042 |
|
|
|
2043 |
|
|
|
2044 |
|
|
</div> |
2045 |
|
|
<a name="methodset_stripslashes" id="set_stripslashes"><!-- --></a> |
2046 |
|
|
<div class="oddrow"> |
2047 |
|
|
|
2048 |
|
|
<div class="method-header"> |
2049 |
|
|
<span class="method-title">set_stripslashes</span> (line <span class="line-number">748</span>) |
2050 |
|
|
</div> |
2051 |
|
|
|
2052 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
2053 |
|
|
<p class="short-description">This sets the stripslashes flag for this object.</p> |
2054 |
|
|
|
2055 |
|
|
<div class="method-signature"> |
2056 |
|
|
<span class="method-result">void</span> |
2057 |
|
|
<span class="method-name"> |
2058 |
|
|
set_stripslashes |
2059 |
|
|
</span> |
2060 |
|
|
([<span class="var-type">boolean</span> <span class="var-name">$flag</span> = <span class="var-default">TRUE</span>]) |
2061 |
|
|
</div> |
2062 |
|
|
|
2063 |
|
|
<ul class="parameters"> |
2064 |
|
|
<li> |
2065 |
|
|
<span class="var-type">boolean</span> |
2066 |
|
|
<span class="var-name">$flag</span> </li> |
2067 |
|
|
</ul> |
2068 |
|
|
|
2069 |
|
|
|
2070 |
|
|
</div> |
2071 |
|
|
<a name="method_test_element" id="_test_element"><!-- --></a> |
2072 |
|
|
<div class="evenrow"> |
2073 |
|
|
|
2074 |
|
|
<div class="method-header"> |
2075 |
|
|
<span class="method-title">_test_element</span> (line <span class="line-number">974</span>) |
2076 |
|
|
</div> |
2077 |
|
|
|
2078 |
|
|
<!-- ========== Info from phpDoc block ========= --> |
2079 |
|
|
<p class="short-description">This method tests to see if we have an element named $label, so we can operate on it.</p> |
2080 |
|
|
|
2081 |
|
|
<div class="method-signature"> |
2082 |
|
|
<span class="method-result">void</span> |
2083 |
|
|
<span class="method-name"> |
2084 |
|
|
_test_element |
2085 |
|
|
</span> |
2086 |
|
|
(<span class="var-type">string</span> <span class="var-name">$label</span>, <span class="var-type">string</span> <span class="var-name">$method</span>, [<span class="var-type">boolean</span> <span class="var-name">$hidden</span> = <span class="var-default">FALSE</span>]) |
2087 |
|
|
</div> |
2088 |
|
|
|
2089 |
|
|
<ul class="parameters"> |
2090 |
|
|
<li> |
2091 |
|
|
<span class="var-type">string</span> |
2092 |
|
|
<span class="var-name">$label</span><span class="var-description">: <p>- the element's label</p></span> </li> |
2093 |
|
|
<li> |
2094 |
|
|
<span class="var-type">string</span> |
2095 |
|
|
<span class="var-name">$method</span><span class="var-description">: <p>- the name of the method that called us</p></span> </li> |
2096 |
|
|
<li> |
2097 |
|
|
<span class="var-type">boolean</span> |
2098 |
|
|
<span class="var-name">$hidden</span><span class="var-description">: <p>- test a hidden element?</p></span> </li> |
2099 |
|
|
</ul> |
2100 |
|
|
|
2101 |
|
|
|
2102 |
|
|
</div> |
2103 |
|
|
|
2104 |
|
|
</div> |
2105 |
|
|
</div> |
2106 |
|
|
|
2107 |
|
|
<p class="notes" id="credit"> |
2108 |
|
|
Documention generated on Thu, 31 Jul 2003 18:32:42 -0700 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.2.0</a> |
2109 |
|
|
</p> |
2110 |
|
|
</div></body> |
2111 |
jonen |
1.1 |
</html> |