'section' => $active_section,
'item' => $item,
'ecml_enabled' => $ecml_enabled,
- 'ecml_keyword' => ($ecml_valid_keyword) ? $active_section : 'entity'
+ 'ecml_keyword' => ($ecml_valid_keyword) ? $active_section : 'entity',
+ 'icon_size' => elgg_get_array_value('icon_size', $section_info, 'tiny'),
);
$items_content .= elgg_view($view, $item_params);
$section = $vars['section'];
$target = $vars['target'];
$ecml_keyword = (isset($vars['ecml_enabled']) && isset($vars['ecml_keyword'])) ? $vars['ecml_keyword'] : NULL;
+$icon_size = $vars['icon_size'];
// @todo add entity checking.
$embed_code = "[$ecml_keyword guid={$item->getGUID()}]";
} else {
// fallback to inserting a hard link to the object with its icon
- $icon = "<img src=\"{$item->getIcon('medium')}\" />" . htmlentities($title, ENT_QUOTES, 'UTF-8');
+ $icon = "<img src=\"{$item->getIcon($icon_size)}\" />" . htmlentities($title, ENT_QUOTES, 'UTF-8');
$embed_code = elgg_view('output/url', array(
'href' => $item->getURL(),
));
}
-$icon = "<img src=\"{$item->getIcon('medium')}\" />";
+$icon = "<img src=\"{$item->getIcon($icon_size)}\" />";
$info = htmlentities($title, ENT_QUOTES, 'UTF-8');
$listing = elgg_view('entities/gallery_listing', array('icon' => $icon, 'info' => $info));
$section = $vars['section'];
$target = $vars['target'];
$ecml_keyword = (isset($vars['ecml_enabled']) && isset($vars['ecml_keyword'])) ? $vars['ecml_keyword'] : NULL;
+$icon_size = $vars['icon_size'];
// @todo add entity checking.
$embed_code = "[$ecml_keyword guid={$item->getGUID()}]";
} else {
// fallback to inserting a hard link to the object with its icon
- $icon = "<img src=\"{$item->getIcon()}\" />" . htmlentities($title, ENT_QUOTES, 'UTF-8');
+ $icon = "<img src=\"{$item->getIcon($icon_size)}\" />" . htmlentities($title, ENT_QUOTES, 'UTF-8');
$embed_code = elgg_view('output/url', array(
'href' => $item->getURL(),
));
}
-$icon = "<img src=\"{$item->getIcon('tiny')}\" />";
+$icon = "<img src=\"{$item->getIcon($icon_size)}\" />";
$info = htmlentities($title, ENT_QUOTES, 'UTF-8');
// @todo is this approach better than inline js?