Elgg
Version 2.3
engine
classes
Elgg
Menu
Menu.php
Go to the documentation of this file.
1
<?php
2
namespace
Elgg\Menu
;
3
4
use
ElggMenuItem
;
5
11
class
Menu
{
12
16
private
$params;
17
27
public
function
__construct
(array $params) {
28
$this->params =
$params
;
29
}
30
36
public
function
getSections
() {
37
return
$this->params[
'menu'
];
38
}
39
48
public
function
getSection
(
$name
,
$default
=
null
) {
49
return
isset($this->params[
'menu'
][
$name
]) ? $this->params[
'menu'
][
$name
] :
$default
;
50
}
51
57
public
function
getName
() {
58
return
$this->params[
'name'
];
59
}
60
66
public
function
getParams
() {
67
return
$this->params;
68
}
69
}
$params
$params
Definition:
login.php:72
$name
if($guid==elgg_get_logged_in_user_guid()) $name
Definition:
delete.php:21
ElggMenuItem
Definition:
ElggMenuItem.php:15
Elgg\Menu\Menu
A complete menu, sorted, filtered by the "prepare" hook, and split into sections.
Definition:
Menu.php:11
Elgg\Menu\Menu\getParams
getParams()
Get the menu parameters.
Definition:
Menu.php:66
Elgg\Menu\Menu\getSections
getSections()
Get all menu sections.
Definition:
Menu.php:36
Elgg\Menu\Menu\__construct
__construct(array $params)
Constructor.
Definition:
Menu.php:27
Elgg\Menu\Menu\getSection
getSection($name, $default=null)
Get a single menu section.
Definition:
Menu.php:48
Elgg\Menu\Menu\getName
getName()
Get the menu's name.
Definition:
Menu.php:57
$default
$default
Definition:
checkbox.php:34
Elgg\Menu
Definition:
Menu.php:2
Generated on Fri Aug 29 2025 00:00:46 for Elgg by
1.9.1