PHP Класс MenuModule, vanilla

Наследование: extends CWebModule
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$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.

Открытые методы

Метод Описание
__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

Описание методов

__construct() публичный Метод

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

addItem() публичный Метод

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

assetTarget() публичный Метод

public assetTarget ( ) : string
Результат string

clearGroups() публичный Метод

public clearGroups ( )

highlightRoute() публичный Метод

public highlightRoute ( $Route )
$Route

removeGroup() публичный Метод

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

toString() публичный Метод

public toString ( string $HighlightRoute = '' ) : string
$HighlightRoute string
Результат string

Описание свойств

$CssClass публичное свойство

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

$HtmlId публичное свойство

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

$Items публичное свойство

Menu items.
public $Items

$Sort публичное свойство

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