Search moodle.org's
Developer Documentation

See Release Notes
Long Term Support Release

  • Bug fixes for general core bugs in 4.1.x will end 13 November 2023 (12 months).
  • Bug fixes for security issues in 4.1.x will end 10 November 2025 (36 months).
  • PHP version: minimum PHP 7.4.0 Note: minimum PHP version has increased since Moodle 4.0. PHP 8.0.x is supported too.

(no description)

File Size: 159 lines (5 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 2 classes

HTML_QuickForm_Renderer:: (2 methods):
  __construct()
  HTML_QuickForm_Renderer()

name:: (8 methods):
  startForm()
  finishForm()
  renderHeader()
  renderElement()
  renderHidden()
  renderHtml()
  startGroup()
  finishGroup()


Class: HTML_QuickForm_Renderer  - X-Ref

An abstract base class for QuickForm renderers

The class implements a Visitor design pattern

__construct()   X-Ref
Constructor


HTML_QuickForm_Renderer()   X-Ref
Old syntax of class constructor. Deprecated in PHP7.


Class: name  - X-Ref

startForm(&$form)   X-Ref
Called when visiting a form, before processing any form elements

param: object    An HTML_QuickForm object being visited
return: void

finishForm(&$form)   X-Ref
Called when visiting a form, after processing all form elements

param: object     An HTML_QuickForm object being visited
return: void

renderHeader(&$header)   X-Ref
Called when visiting a header element

param: object     An HTML_QuickForm_header element being visited
return: void

renderElement(&$element, $required, $error)   X-Ref
Called when visiting an element

param: object     An HTML_QuickForm_element object being visited
param: bool       Whether an element is required
param: string     An error message associated with an element
return: void

renderHidden(&$element)   X-Ref
Called when visiting a hidden element

param: object     An HTML_QuickForm_hidden object being visited
return: void

renderHtml(&$data)   X-Ref
Called when visiting a raw HTML/text pseudo-element

Seems that this should not be used when using a template-based renderer

param: object     An HTML_QuickForm_html element being visited
return: void

startGroup(&$group, $required, $error)   X-Ref
Called when visiting a group, before processing any group elements

param: object     An HTML_QuickForm_group object being visited
param: bool       Whether a group is required
param: string     An error message associated with a group
return: void

finishGroup(&$group)   X-Ref
Called when visiting a group, after processing all group elements

param: object     An HTML_QuickForm_group object being visited
return: void