Elgg  Version master
content.php
Go to the documentation of this file.
1 <?php
2 
3 // don't show content for default widgets
4 if (elgg_in_context('default_widgets')) {
5  return;
6 }
7 
8 $widget = elgg_extract('entity', $vars);
9 if (!$widget instanceof \ElggWidget) {
10  return;
11 }
12 
13 echo elgg_view("widgets/{$widget->handler}/content", $vars);
if(elgg_in_context('default_widgets')) $widget
Definition: content.php:8
elgg_in_context(string $context)
Check if this context exists anywhere in the stack.
Definition: context.php:78
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:177
$vars
Definition: theme.php:5