MDL-52081 forms: Use __construct() for constructors

This commit is contained in:
Marina Glancy
2015-12-10 13:38:01 +08:00
parent 0dfcc2541a
commit 1a0df5535e
83 changed files with 1014 additions and 208 deletions
+11 -1
View File
@@ -53,8 +53,18 @@ class moodlequickform_guideeditor extends HTML_QuickForm_input {
* @param string $elementlabel
* @param array $attributes
*/
public function __construct($elementname=null, $elementlabel=null, $attributes=null) {
parent::__construct($elementname, $elementlabel, $attributes);
}
/**
* Old syntax of class constructor. Deprecated in PHP7.
*
* @deprecated since Moodle 3.1
*/
public function moodlequickform_guideeditor($elementname=null, $elementlabel=null, $attributes=null) {
parent::HTML_QuickForm_input($elementname, $elementlabel, $attributes);
debugging('Use of class name as constructor is deprecated', DEBUG_DEVELOPER);
self::__construct($elementname, $elementlabel, $attributes);
}
/**