Overview

Packages

  • bootstrap
    • behaviors
    • components
    • form
    • gii
    • helpers
    • widgets

Classes

  • TbActiveForm
  • TbAffix
  • TbAlert
  • TbBreadcrumb
  • TbButtonColumn
  • TbCollapse
  • TbDataColumn
  • TbDetailView
  • TbGridView
  • TbHeroUnit
  • TbListView
  • TbModal
  • TbNav
  • TbNavbar
  • TbPager
  • TbScrollspy
  • TbTabs
  • TbThumbnails
  • TbTypeAhead
  • Overview
  • Package
  • Class
  • Tree

Class TbNav

Bootstrap navigation menu widget.

CWidget
Extended by TbNav
Package: bootstrap\widgets
Copyright: Copyright © Christoffer Niska 2013-
License: New BSD License
Author: Christoffer Niska <christoffer.niska@gmail.com>
See: http://twitter.github.com/bootstrap/components.html#navbar
Located at widgets/TbNav.php
Methods summary
public
# init( )

Initializes the widget.

Initializes the widget.

public
# run( )

Runs the widget.

Runs the widget.

protected array
# normalizeItems( array $items, string $route, boolean & $active )

Normalizes the menu items.

Normalizes the menu items.

Parameters

$items
array
$items the items to be normalized.
$route
string
$route the route of the current request.
$active
boolean
$active whether there is an active child menu item.

Returns

array
the normalized menu items.
protected boolean
# isItemActive( array $item, string $route )

Checks whether a menu item is active.

Checks whether a menu item is active.

Parameters

$item
array
$item the menu item to be checked.
$route
string
$route the route of the current request.

Returns

boolean
whether the menu item is active.
Properties summary
public string $type
#

the menu type.

the menu type.

public boolean $stacked false
#

whether the menu items should be stacked on top of each other.

whether the menu items should be stacked on top of each other.

public string|array $scrollspy
#

the scrollspy target or configuration.

the scrollspy target or configuration.

public array $items array()
#

list of menu items. Each menu item is specified as an array of name-value pairs.

list of menu items. Each menu item is specified as an array of name-value pairs.

public boolean $encodeLabel true
#

whether the labels for menu items should be HTML-encoded. Defaults to true.

whether the labels for menu items should be HTML-encoded. Defaults to true.

public boolean $activateItems true
#

whether to automatically activate items according to whether their route setting matches the currently requested route. Defaults to true.

whether to automatically activate items according to whether their route setting matches the currently requested route. Defaults to true.

public boolean $activateParents false
#

whether to activate parent menu items when one of the corresponding child menu items is active.

whether to activate parent menu items when one of the corresponding child menu items is active.

public boolean $hideEmptyItems true
#

whether to hide empty menu items.

whether to hide empty menu items.

public array $htmlOptions array()
#

HTML attributes for the menu's root container tag.

HTML attributes for the menu's root container tag.

Yiistrap API documentation generated by ApiGen 2.8.0