Heading
Extends \Joomla\CMS\Menu\NodeA Heading type of node for MenuTree
see | \Joomla\CMS\Menu\Node |
---|---|
since |
3.8.0 |
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Methods
__construct
Constructor
__construct()
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
addChild
Add child to this node
addChild(\Joomla\CMS\Menu\Node $child) : \Joomla\CMS\Menu\Node
If the child already has a parent, the link is unset
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Arguments
- $child
\Joomla\CMS\Menu\Node
The child to be added
Response
\Joomla\CMS\Menu\Node
The new added child
get
Get an attribute value
get(string $name) : mixed
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Arguments
- $name
string
The attribute name
Response
mixed
getChildren
Get the children of this node
getChildren() : array<mixed,\Joomla\CMS\Menu\Node>
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Response
array<mixed,\Joomla\CMS\Menu\Node>
The children
getLevel
Find the current node depth in the tree hierarchy
getLevel() : integer
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Response
integer
The node level in the hierarchy, where ROOT == 0, First level menu item == 1, and so on.
getParam
Get the param value from the node params
getParam(string $key) : mixed
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Arguments
- $key
string
The param name
Response
mixed
getParent
Get the parent of this node
getParent() : \Joomla\CMS\Menu\Node
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Response
\Joomla\CMS\Menu\Node
The Node object's parent or null for no parent
hasChildren
Test if this node has children
hasChildren() : boolean
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Response
boolean
hasParent
Test if this node has a parent
hasParent() : boolean
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Response
boolean
True if there is a parent
isRoot
Check whether the object instance node is the root node
isRoot() : boolean
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Response
boolean
removeChild
Remove a child from this node
removeChild(\Joomla\CMS\Menu\Node $child) : void
If the child exists it is unset
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Arguments
- $child
\Joomla\CMS\Menu\Node
The child to be added
setActive
Set the active state on or off
setActive(boolean $active) : void
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Arguments
- $active
boolean
The new active state
setParams
set the params array
setParams(\Joomla\Registry\Registry $params) : void
since |
3.8.0 |
---|---|
deprecated |
4.0 Use Joomla\CMS\Menu\MenuItem |
Arguments
- $params
\Joomla\Registry\Registry
The params attributes
Properties
title
Node Title
since |
3.8.0 |
---|
Type(s)
string
link
Node Link
since |
3.8.0 |
---|
Type(s)
string
icon
Link title icon
since |
3.8.0 |
---|
Type(s)
string
id
Node Id
since |
3.8.0 |
---|
Type(s)
string
class
CSS Class for node
since |
3.8.0 |
---|
Type(s)
string
active
Whether this node is active
since |
3.8.0 |
---|
Type(s)
boolean
children
Array of Children node objects