Definition at line 18 of file formselect.php.
◆ __construct()
__construct |
( |
| $caption, |
|
|
| $name, |
|
|
| $value = null, |
|
|
| $size = 1, |
|
|
| $multiple = false ) |
Constructor
- Parameters
-
string | $caption | Caption |
string | $name | "name" attribute |
mixed | $value | Pre-selected value (or array of them). |
int | $size | Number or rows. "1" makes a drop-down-list |
bool | $multiple | Allow multiple selections? |
Definition at line 58 of file formselect.php.
◆ addOption()
addOption |
( |
| $value, |
|
|
| $name = '' ) |
Add an option
- Parameters
-
string | $value | "value" attribute |
string | $name | "name" attribute |
Definition at line 121 of file formselect.php.
◆ addOptionArray()
addOptionArray |
( |
| $options | ) |
|
Add multiple options
- Parameters
-
array | $options | Associative array of value->name pairs |
Definition at line 135 of file formselect.php.
◆ getOptions()
Get all options
- Returns
- array Associative array of value->name pairs
Definition at line 149 of file formselect.php.
◆ getSize()
◆ getValue()
Get an array of pre-selected values
- Returns
- array
Definition at line 94 of file formselect.php.
◆ isMultiple()
Are multiple selections allowed?
- Returns
- bool
Definition at line 74 of file formselect.php.
◆ render()
◆ setValue()
◆ $_multiple
◆ $_options
◆ $_size
◆ $_value
The documentation for this class was generated from the following file: