Moodle APIs  3.8
Moodle 3.8.6 (Build: 20201109)
Public Member Functions | Public Attributes | List of all members
MoodleQuickForm_passwordunmask Class Reference
Inheritance diagram for MoodleQuickForm_passwordunmask:
MoodleQuickForm_password templatable

Public Member Functions

 __construct ($elementName=null, $elementLabel=null, $attributes=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...
 
 getHelpButton ()
 get html for help button More...
 
 MoodleQuickForm_password ($elementName=null, $elementLabel=null, $attributes=null)
 Old syntax of class constructor. More...
 
 MoodleQuickForm_passwordunmask ($elementName=null, $elementLabel=null, $attributes=null)
 Old syntax of class constructor. More...
 
 validateSubmitValue ($value)
 Check that there is no whitespace at the beginning and end of the password. More...
 

Public Attributes

 $_helpbutton =''
 
 string
 html for help button, if empty then no help
 

Constructor & Destructor Documentation

◆ __construct()

MoodleQuickForm_passwordunmask::__construct (   $elementName = null,
  $elementLabel = null,
  $attributes = null 
)

constructor

Parameters
string$elementName(optional) name of the password element
string$elementLabel(optional) label for password element
mixed$attributes(optional) Either a typical HTML attribute string or an associative array

Reimplemented from MoodleQuickForm_password.

Member Function Documentation

◆ export_for_template()

MoodleQuickForm_passwordunmask::export_for_template ( renderer_base  $output)

Function to export the renderer data in a format that is suitable for a mustache template.

Parameters
renderer_base$outputUsed to do a final render of any components that need to be rendered for export.
Return values
stdClass|array

Implements templatable.

◆ getHelpButton()

MoodleQuickForm_password::getHelpButton ( )
inherited

get html for help button

Return values
stringhtml for help button

◆ MoodleQuickForm_password()

MoodleQuickForm_password::MoodleQuickForm_password (   $elementName = null,
  $elementLabel = null,
  $attributes = null 
)
inherited

Old syntax of class constructor.

Deprecated in PHP7.

Deprecated:
since Moodle 3.1

◆ MoodleQuickForm_passwordunmask()

MoodleQuickForm_passwordunmask::MoodleQuickForm_passwordunmask (   $elementName = null,
  $elementLabel = null,
  $attributes = null 
)

Old syntax of class constructor.

Deprecated in PHP7.

Deprecated:
since Moodle 3.1

◆ validateSubmitValue()

MoodleQuickForm_passwordunmask::validateSubmitValue (   $value)

Check that there is no whitespace at the beginning and end of the password.

It turned out that wrapping whitespace can easily be pasted by accident when copying the text from elsewhere. Such a mistake is very hard to debug as the whitespace is not displayed.

Parameters
array$valueSubmitted value.
Return values
string|nullValidation error message or null.

The documentation for this class was generated from the following file: