select type form element Contains HTML class for a select type element with options containing link
Copyright: | 2008 Nicolas Connault <nicolasconnault@gmail.com> |
License: | http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later |
File Size: | 275 lines (9 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 1 file lib/form/templatable_form_element.php |
MoodleQuickForm_selectwithlink:: (2 methods):
__construct()
MoodleQuickForm_selectwithlink()
name:: (8 methods):
setHiddenLabel()
toHtml()
getHelpButton()
removeOption()
removeOptions()
getElementTemplateType()
exportValue()
export_for_template()
Class: MoodleQuickForm_selectwithlink - X-Ref
select type form element__construct($elementName=null, $elementLabel=null, $options=null, $attributes=null, $linkdata=null) X-Ref |
constructor param: string $elementName Select name attribute param: mixed $elementLabel Label(s) for the select param: array $options Data to be used to populate options param: mixed $attributes Either a typical HTML attribute string or an associative array param: bool $linkdata data to be posted |
MoodleQuickForm_selectwithlink($elementName=null, $elementLabel=null, $options=null, $attributes=null, $linkdata=null) X-Ref |
Old syntax of class constructor. Deprecated in PHP7. |
setHiddenLabel($hiddenLabel) X-Ref |
Sets label to be hidden param: bool $hiddenLabel sets if label should be hidden |
toHtml() X-Ref |
Returns the SELECT in HTML return: string |
getHelpButton() X-Ref |
get html for help button return: string html for help button |
removeOption($value) X-Ref |
Removes an OPTION from the SELECT param: string $value Value for the OPTION to remove |
removeOptions() X-Ref |
Removes all OPTIONs from the SELECT |
getElementTemplateType() X-Ref |
Slightly different container template when frozen. Don't want to use a label tag with a for attribute in that case for the element label but instead use a div. Templates are defined in renderer constructor. return: string |
exportValue(&$submitValues, $assoc = false) X-Ref |
We check the options and return only the values that _could_ have been selected. We also return a scalar value if select is not "multiple" param: array $submitValues submitted values param: bool $assoc if true the retured value is associated array return: mixed |
export_for_template(renderer_base $output) X-Ref |
No description |