Permalink
Browse files

MDL-32316 feedback: fix tem type label does honor trusted text

  • Loading branch information...
1 parent 4b3ee4f commit c5c7879f8b73bcd6df6d9a110e4c728830797d6e @grabs grabs committed Apr 9, 2012
Showing with 4 additions and 2 deletions.
  1. +1 −1 mod/feedback/item/label/label_form.php
  2. +3 −1 mod/feedback/item/label/lib.php
@@ -29,7 +29,7 @@ function definition() {
$mform->addElement('header', 'general', get_string($this->type, 'feedback'));
$mform->addElement('editor', 'presentation_editor', '', null, $presentationoptions);
- $mform->setType('presentation_editor', PARAM_CLEANHTML);
+ $mform->setType('presentation_editor', PARAM_RAW);
parent::definition();
$this->set_data($item);
@@ -135,7 +135,9 @@ function print_item($item){
$item->presentationtrust = 1;
$output = file_rewrite_pluginfile_urls($item->presentation, 'pluginfile.php', $context->id, 'mod_feedback', $filearea, $item->id);
- echo format_text($output, FORMAT_HTML, array('overflowdiv'=>true));
+
+ $formatoptions = array('overflowdiv'=>true, 'trusted'=>$CFG->enabletrusttext);
+ echo format_text($output, FORMAT_HTML, $formatoptions);
}
/**

0 comments on commit c5c7879

Please sign in to comment.