diff --git a/mod/data/lib.php b/mod/data/lib.php index ffbb3a90cb5..8085ef1ce0a 100755 --- a/mod/data/lib.php +++ b/mod/data/lib.php @@ -799,9 +799,9 @@ function data_print_template($records, $data, $search, $template, $sort, $page=0 ///actual replacement of the tags $newtext = preg_replace($patterns, $replacement, $data->{$template}); if ($return) { - return $newtext; + return format_text($newtext); } else { - echo $newtext; //prints the template with tags replaced + echo format_text($newtext); //prints the template with tags replaced } /********************************** @@ -1095,7 +1095,7 @@ function data_print_comment($data, $commentid) { print_user_picture($comment->userid, $course->id, false); echo ''; - echo '