Elgg
Version master
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
views
default
trash
elements
metadata.php
Go to the documentation of this file.
1
<?php
10
$metadata
=
elgg_extract
(
'metadata'
,
$vars
);
11
if
(!isset(
$metadata
)) {
12
$metadata
=
''
;
13
14
$entity
=
elgg_extract
(
'entity'
,
$vars
);
15
16
$show_entity_menu =
elgg_extract
(
'show_trash_menu'
,
$vars
,
true
);
17
if
($show_entity_menu) {
18
$metadata
.=
elgg_view_menu
(
'entity:trash'
, [
19
'entity'
=>
$entity
,
20
'prepare_dropdown'
=>
true
,
21
]);
22
}
23
}
24
25
if
(!
$metadata
) {
26
return
;
27
}
28
29
echo
elgg_format_element
(
'div'
, [
30
'class'
=>
'elgg-listing-summary-metadata'
31
],
$metadata
);
elgg_extract
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_menu
elgg_view_menu($menu, array $vars=[])
Render a menu.
Definition:
views.php:441
$entity
$entity
Definition:
reset.php:8
$vars
$vars
Definition:
theme.php:5
$metadata
$metadata
Output annotation metadata.
Definition:
metadata.php:9
elgg_format_element
elgg_format_element(string $tag_name, array $attributes=[], string $text= '', array $options=[])
Format an HTML element.
Definition:
output.php:145
Generated on Sat Dec 21 2024 00:02:53 for Elgg by
1.8.11