MDL-76866 mod_data: Editors should have data-fieldtype attrib

This commit is contained in:
Andrew Nicols
2023-03-29 20:33:47 +08:00
parent 4782312411
commit 96fd7a83fb
+1
View File
@@ -185,6 +185,7 @@ class data_field_textarea extends data_field_base {
$str .= '<input type="hidden" name="'.$field.'_itemid" value="'.s($draftitemid).'" />';
$str .= '<div class="mod-data-input">';
$str .= '<div><textarea id="'.$field.'" name="'.$field.'" rows="'.$this->field->param3.'" class="form-control" ' .
'data-fieldtype="editor" ' .
'cols="'.$this->field->param2.'" spellcheck="true">'.s($text).'</textarea></div>';
$str .= '<div><label class="accesshide" for="' . $field . '_content1">' . get_string('format') . '</label>';
$str .= '<select id="' . $field . '_content1" name="'.$field.'_content1">';