PHP Class MenuModule, vanilla

Inheritance: extends CWebModule
Datei anzeigen Open project: vanilla/vanilla Class Usage Examples

Public Properties

Property Type Description
$CssClass The class attribute to be applied to the root element of the breadcrumb. Default is none.
$HtmlId The html id attribute to be applied to the root element of the menu.vDefault is "Menu".
$Items Menu items.
$Sort Menu group names arranged in the order that the menu should be rendered.

Public Methods

Method Description
__construct ( string $Sender = '' )
addItem ( $Group, $Text, boolean $Permission = false, string $Attributes = '' )
addLink ( $Group, $Text, $Url, boolean $Permission = false, string $Attributes = '', string $AnchorAttributes = '' )
assetTarget ( ) : string
clearGroups ( )
highlightRoute ( $Route )
removeGroup ( $Group ) Removes an entire group of links, and the group itself, from the menu.
removeLink ( $Group, $Text )
removeLinks ( $Group ) Removes all links from a specific group.
toString ( string $HighlightRoute = '' ) : string

Method Details

__construct() public method

public __construct ( string $Sender = '' )
$Sender string

addItem() public method

public addItem ( $Group, $Text, boolean $Permission = false, string $Attributes = '' )
$Group
$Text
$Permission boolean
$Attributes string

assetTarget() public method

public assetTarget ( ) : string
return string

clearGroups() public method

public clearGroups ( )

highlightRoute() public method

public highlightRoute ( $Route )
$Route

removeGroup() public method

Removes an entire group of links, and the group itself, from the menu.
public removeGroup ( $Group )

toString() public method

public toString ( string $HighlightRoute = '' ) : string
$HighlightRoute string
return string

Property Details

$CssClass public_oe property

The class attribute to be applied to the root element of the breadcrumb. Default is none.
public $CssClass

$HtmlId public_oe property

The html id attribute to be applied to the root element of the menu.vDefault is "Menu".
public $HtmlId

$Items public_oe property

Menu items.
public $Items

$Sort public_oe property

Menu group names arranged in the order that the menu should be rendered.
public $Sort