Elgg  Version 4.3
container.php
Go to the documentation of this file.
1 <?php
12 if (!$item instanceof ElggEntity) {
13  return;
14 }
15 
16 $link = elgg_extract('link', $vars, true);
17 
18 $entity = $item->getContainerEntity();
19 if (!$entity) {
20  return;
21 }
22 
23 echo $link ? elgg_view_entity_url($entity) : $entity->getDisplayName();
$entity
Definition: container.php:18
if(!$item instanceof ElggEntity) $link
Definition: container.php:16
elgg_extract($key, $array, $default=null, $strict=true)
Checks for $array[$key] and returns its value if it exists, else returns $default.
Definition: elgglib.php:547
$item
Render a container element.
Definition: container.php:11
elgg echo
Translates a string.
Definition: deprecated.js:530
$vars['head']
Definition: html.php:24
elgg_view_entity_url(\ElggEntity $entity, array $options=[])
Helper function for outputting a link to an entity.
Definition: views.php:1530