Elgg  Version master
default.php
Go to the documentation of this file.
1 <?php
8 $entity = elgg_extract('entity', $vars);
9 if (!$entity instanceof ElggEntity) {
10  return;
11 }
12 
13 if (!isset($vars['icon'])) {
14  $vars['icon'] = true;
15 }
16 
17 if (!isset($vars['title']) && empty($entity->getDisplayName())) {
18  $vars['title'] = get_class($entity);
19 }
20 
21 echo elgg_view('object/elements/summary', $vars);
elgg_extract($key, $array, $default=null, bool $strict=true)
Checks for $array[$key] and returns its value if it exists, else returns $default.
Definition: elgglib.php:254
elgg_view(string $view, array $vars=[], string $viewtype= '')
Return a parsed view.
Definition: views.php:156
if(!array_key_exists($size, $icon_sizes)) $vars['size']
Definition: default.php:25
$entity
Generic icon view.
Definition: default.php:13