MDL-50318 course: Fix the URL of embedded images at resources overview
Not only mod_resource instances are listed here. All modules that declare their FEATURE_MOD_ARCHETYPE as MOD_ARCHETYPE_RESOURCE (well, all but those without own view page, such as mod_label) are listed. So we must use the real plugin name when rendering the intro field.
This commit is contained in:
@@ -134,7 +134,7 @@ foreach ($cms as $cm) {
|
||||
$icon = '<img src="'.$cm->get_icon_url().'" class="activityicon" alt="'.$cm->get_module_type_name().'" /> ';
|
||||
|
||||
if (isset($resource->intro) && isset($resource->introformat)) {
|
||||
$intro = format_module_intro('resource', $resource, $cm->id);
|
||||
$intro = format_module_intro($cm->modname, $resource, $cm->id);
|
||||
} else {
|
||||
$intro = '';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user