Elgg  Version 2.3
full.php
Go to the documentation of this file.
1 <?php
2 
13 $entity = elgg_extract('entity', $vars);
14 if (!$entity instanceof ElggEntity) {
15  elgg_log("object/elements/full expects an ElggEntity in \$vars['entity']", 'ERROR');
16 }
17 
18 $class = elgg_extract_class($vars, ['elgg-listing-full', 'elgg-content', 'clearfix']);
19 unset($vars['class']);
20 
21 $header = elgg_view('object/elements/full/header', $vars);
22 $body = elgg_view('object/elements/full/body', $vars);
23 
25  'class' => $class,
26  'data-guid' => $entity->guid,
27  ], $header . $body);
28 
29 
$header
Definition: full.php:21
$body
Definition: full.php:22
elgg_extract_class(array $array, $existing=[])
Extract class names from an array with key "class", optionally merging into a preexisting set...
Definition: elgglib.php:1396
$vars['entity']
$entity
Object full view.
Definition: full.php:13
elgg_format_element($tag_name, array $attributes=array(), $text= '', array $options=array())
Format an HTML element.
Definition: output.php:208
elgg echo
Translates a string.
Definition: languages.js:48
if(!$entity instanceof ElggEntity) $class
Definition: full.php:18
elgg_view($view, $vars=array(), $ignore1=false, $ignore2=false, $viewtype= '')
Return a parsed view.
Definition: views.php:336
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:1375
elgg_log($message, $level= 'NOTICE')
Display or log a message.
Definition: elgglib.php:1028