MDL-47995 lib: encode title properly, before additing it to image title

This commit is contained in:
Rajesh Taneja 2015-06-04 11:13:00 +08:00
parent 59f7fd42e0
commit 7deb61e7c0

View file

@ -216,7 +216,7 @@ function resourcelib_get_extension($fullurl) {
function resourcelib_embed_image($fullurl, $title) {
$code = '';
$code .= '<div class="resourcecontent resourceimg">';
$code .= "<img title=\"".strip_tags(format_string($title))."\" class=\"resourceimage\" src=\"$fullurl\" alt=\"\" />";
$code .= "<img title=\"".s(strip_tags(format_string($title)))."\" class=\"resourceimage\" src=\"$fullurl\" alt=\"\" />";
$code .= '</div>';
return $code;