Zend Framework
1.12
|
Public Member Functions | |
formSelect ($name, $value=null, $attribs=null, $options=null, $listsep="<br />\n") | |
Generates 'select' list of options. | |
![]() | |
getTranslator () | |
Get translator. | |
setTranslator ($translator=null) | |
Set translator. | |
![]() | |
getClosingBracket () | |
Get the tag closing bracket. | |
![]() | |
setView (Zend_View_Interface $view) | |
Set the View object. | |
direct () | |
Strategy pattern: currently unutilized. | |
Protected Member Functions | |
_build ($value, $label, $selected, $disable, $optionClasses=array()) | |
Builds the actual <option> tag. | |
![]() | |
_getInfo ($name, $value=null, $attribs=null, $options=null, $listsep=null) | |
Converts parameter arguments to an element info array. | |
_hidden ($name, $value=null, $attribs=null) | |
Creates a hidden element. | |
![]() | |
_isXhtml () | |
Is doctype XHTML? | |
_isHtml5 () | |
Is doctype HTML5? | |
_isStrictDoctype () | |
Is doctype strict? | |
_htmlAttribs ($attribs) | |
Converts an associative array to a string of tag attributes. | |
_normalizeId ($value) | |
Normalize an ID. | |
Additional Inherited Members | |
![]() | |
const | EOL = "\n" |
EOL character. | |
![]() | |
$_translator | |
|
protected |
Builds the actual <option> tag.
string | $value | Options Value |
string | $label | Options Label |
array | $selected | The option value(s) to mark as 'selected' |
array | bool | $disable | Whether the select is disabled, or individual options are |
array | $optionClasses | The classes to associate with each option value |
formSelect | ( | $name, | |
$value = null , |
|||
$attribs = null , |
|||
$options = null , |
|||
$listsep = "<br />\n" |
|||
) |
Generates 'select' list of options.
public
string | array | $name | If a string, the element name. If an array, all other parameters are ignored, and the array elements are extracted in place of added parameters. |
mixed | $value | The option value to mark as 'selected'; if an array, will mark all values in the array as 'selected' (used for multiple-select elements). |
array | string | $attribs | Attributes added to the 'select' tag. the optional 'optionClasses' attribute is used to add a class to the options within the select (associative array linking the option value to the desired class) |
array | $options | An array of key-value pairs where the array key is the radio value, and the array value is the radio text. |
string | $listsep | When disabled, use this list separator string between list values. |