auFormInteger: Difference between revisions
Appearance
Misterhaan (talk | contribs) New page: {{RightTOC}} FormInteger Category:Class Category:PHP The auFormInteger class is part of the auLib package. It is defined in the auForm.php file. ;Hierarchy ... |
Misterhaan (talk | contribs) →new auFormInteger: add minval, maxval, step |
||
Line 15: | Line 15: | ||
==Public Functions== | ==Public Functions== | ||
===new auFormInteger=== | ===new auFormInteger=== | ||
<code>new auFormInteger($name, ''$label'', ''$tooltip'', ''$required'', ''$default'', ''$width'', ''$maxlength'')</code> | <code>new auFormInteger($name, ''$label'', ''$tooltip'', ''$required'', ''$default'', ''$width'', ''$maxlength'', ''$minval'', ''$maxval'', ''$step'')</code> | ||
Creates a new integer input form field. | Creates a new integer input form field. | ||
Line 25: | Line 25: | ||
* ''$width'' = Width of the field in characters. Default is browser default. | * ''$width'' = Width of the field in characters. Default is browser default. | ||
* ''$maxlength'' = The maximum number of characters the field can accept. Default is unlimited. | * ''$maxlength'' = The maximum number of characters the field can accept. Default is unlimited. | ||
* ''$minval'' = The minimum acceptable value the field can accept. Default is no minimum. | |||
* ''$maxval'' = The maximum acceptable value the field can accept. Default is no maximum. | |||
* ''$step'' = Values must be a multiple of this number. Default is 1. |
Latest revision as of 14:26, 1 February 2011
The auFormInteger class is part of the auLib package. It is defined in the auForm.php file.
- Hierarchy
- auFormElement
- auFormField
- auFormNumber
- auFormInteger
- auFormNumber
- auFormField
Usage
This class is used to add an integer input field to a form. Create an object from this class and add it to an auFormContainer object.
Public Functions
new auFormInteger
new auFormInteger($name, $label, $tooltip, $required, $default, $width, $maxlength, $minval, $maxval, $step)
Creates a new integer input form field.
- $name = Name to submit the field as.
- $label = Label to display with the field. Default is blank.
- $tooltip = Tooltip text to display when the mouse is over the label. Default is none.
- $required = Whether a value is required in this field. Default is not required.
- $default = Default value for this field. Default is blank / unchecked.
- $width = Width of the field in characters. Default is browser default.
- $maxlength = The maximum number of characters the field can accept. Default is unlimited.
- $minval = The minimum acceptable value the field can accept. Default is no minimum.
- $maxval = The maximum acceptable value the field can accept. Default is no maximum.
- $step = Values must be a multiple of this number. Default is 1.