Moodle APIs 3.9
Moodle 3.9.13+ (Build: 20220325)
|
Public Member Functions | |
__construct ($elementName=null, $elementLabel=null, $attributes=null, $options=null) | |
Constructor. More... | |
export_for_template (renderer_base $output) | |
Function to export the renderer data in a format that is suitable for a mustache template. More... | |
getAreamaxbytes () | |
Returns the maximum size of the area. More... | |
getElementTemplateType () | |
Returns type of editor element. More... | |
getFormat () | |
Returns editor format. More... | |
getFrozenHtml () | |
What to display when element is frozen. More... | |
getHelpButton () | |
Returns html for help button. More... | |
getMaxbytes () | |
Returns maximum file size which can be uploaded. More... | |
getMaxfiles () | |
Returns maximum number of files which can be uploaded. More... | |
getName () | |
Returns name of element. More... | |
getSubdirs () | |
Returns true if subdirectoy can be created, else false. More... | |
getValue () | |
Returns editor values. More... | |
isRequired () | |
Checks if editor used is a required field. More... | |
MoodleQuickForm_editor ($elementName=null, $elementLabel=null, $attributes=null, $options=null) | |
Old syntax of class constructor. More... | |
onQuickFormEvent ($event, $arg, &$caller) | |
Called by HTML_QuickForm whenever form event is made on this element. More... | |
setAreamaxbytes ($areamaxbytes) | |
Sets the maximum size of the area. More... | |
setHelpButton ($_helpbuttonargs, $function='_helpbutton') | |
setMaxbytes ($maxbytes) | |
Sets maximum file size which can be uploaded. More... | |
setMaxfiles ($num) | |
Sets maximum number of files which can be uploaded. More... | |
setName ($name) | |
Sets name of editor. More... | |
setSubdirs ($allow) | |
Set option to create sub directory, while uploading file. More... | |
setValue ($values) | |
Updates editor values, if part of $_values. More... | |
toHtml () | |
Returns HTML for editor form element. More... | |
Public Attributes | |
string | $_helpbutton = '' |
html for help button, if empty then no help will icon will be dispalyed. | |
string | $_type = 'editor' |
defines the type of editor | |
Protected Attributes | |
array | $_options |
options provided to initalize filepicker More... | |
array | $_values = array('text'=>null, 'format'=>null, 'itemid'=>null) |
values for editor | |
MoodleQuickForm_editor::__construct | ( | $elementName = null , |
|
$elementLabel = null , |
|||
$attributes = null , |
|||
$options = null |
|||
) |
Constructor.
string | $elementName | (optional) name of the editor |
string | $elementLabel | (optional) editor label |
array | $attributes | (optional) Either a typical HTML attribute string or an associative array |
array | $options | set of options to initalize filepicker |
MoodleQuickForm_editor::export_for_template | ( | renderer_base | $output | ) |
Function to export the renderer data in a format that is suitable for a mustache template.
This means:
renderer_base | $output | Used to do a final render of any components that need to be rendered for export. |
stdClass|array |
Implements templatable.
MoodleQuickForm_editor::getAreamaxbytes | ( | ) |
Returns the maximum size of the area.
int |
MoodleQuickForm_editor::getElementTemplateType | ( | ) |
Returns type of editor element.
string |
MoodleQuickForm_editor::getFormat | ( | ) |
Returns editor format.
int. |
MoodleQuickForm_editor::getFrozenHtml | ( | ) |
What to display when element is frozen.
empty | string |
MoodleQuickForm_editor::getHelpButton | ( | ) |
Returns html for help button.
string | html for help button |
MoodleQuickForm_editor::getMaxbytes | ( | ) |
Returns maximum file size which can be uploaded.
int |
MoodleQuickForm_editor::getMaxfiles | ( | ) |
Returns maximum number of files which can be uploaded.
int |
MoodleQuickForm_editor::getName | ( | ) |
Returns name of element.
string |
MoodleQuickForm_editor::getSubdirs | ( | ) |
Returns true if subdirectoy can be created, else false.
bool |
MoodleQuickForm_editor::getValue | ( | ) |
Returns editor values.
array |
MoodleQuickForm_editor::isRequired | ( | ) |
Checks if editor used is a required field.
bool | true if required field. |
MoodleQuickForm_editor::MoodleQuickForm_editor | ( | $elementName = null , |
|
$elementLabel = null , |
|||
$attributes = null , |
|||
$options = null |
|||
) |
MoodleQuickForm_editor::onQuickFormEvent | ( | $event, | |
$arg, | |||
& | $caller | ||
) |
Called by HTML_QuickForm whenever form event is made on this element.
string | $event | Name of event |
mixed | $arg | event arguments |
object | $caller | calling object |
bool |
MoodleQuickForm_editor::setAreamaxbytes | ( | $areamaxbytes | ) |
Sets the maximum size of the area.
int | $areamaxbytes | size limit |
MoodleQuickForm_editor::setHelpButton | ( | $_helpbuttonargs, | |
$function = '_helpbutton' |
|||
) |
MoodleQuickForm_editor::setMaxbytes | ( | $maxbytes | ) |
Sets maximum file size which can be uploaded.
int | $maxbytes | file size |
MoodleQuickForm_editor::setMaxfiles | ( | $num | ) |
Sets maximum number of files which can be uploaded.
int | $num | number of files |
MoodleQuickForm_editor::setName | ( | $name | ) |
Sets name of editor.
string | $name | name of the editor |
MoodleQuickForm_editor::setSubdirs | ( | $allow | ) |
Set option to create sub directory, while uploading file.
bool | $allow | true if sub directory can be created. |
MoodleQuickForm_editor::setValue | ( | $values | ) |
Updates editor values, if part of $_values.
array | $values | associative array of values to set |
MoodleQuickForm_editor::toHtml | ( | ) |
Returns HTML for editor form element.
string |
|
protected |
options provided to initalize filepicker