Hello,
I want to replace the standard textarea with an editor but I have this error :
mysqli::real_escape_string() expects parameter 1 to be string, array given
The doc is not very well documented about saving data from editor.
I have this in lib.php
public function edit_instance_form($instance, MoodleQuickForm $mform, $context) {
...
$mform->addElement('editor', 'customtext1', get_string('message', $this->plugin_name));
$mform->setType('customtext1', PARAM_TEXT);
$mform->setDefault('customtext1', array('text'=>"Hello"));
}
I think that editor doesn't send string, but how can I do ?