Back to Joomla project (class list)

Class Menu - list of methods

Utility class working with menu select lists
Package: Joomla\CMS\HTML\Helpers
Copyright: (C) 2007 Open Source Matters, Inc.
License: GNU General Public License version 2 or later; see LICENSE.txt
Located at: Joomla/HTML/Helpers/Menu.php
Project: Joomla

Method Summary

public static array
(mixed $clientId = 0)

Get a list of the available menus.
Parameters
  • int $clientId The client id
Returns
  • array
Since
  • 1.6
Show source code of this method: menus Source Code

public static array
(mixed $config = array())

Returns an array of menu items grouped by menu.
Parameters
  • array $config An array of configuration options [published, checkacl, clientid].
Returns
  • array
Since
  • 1.6
Show source code of this method: menuItems Source Code

public static string
(mixed $name, mixed $selected = null, mixed $attribs = null, mixed $config = array())

Displays an HTML select list of menu items.
Parameters
  • string $name The name of the control.
  • string $selected The value of the selected option.
  • string $attribs Attributes for the control.
  • array $config An array of options for the control [id, published, checkacl, clientid].
Returns
  • string
Since
  • 1.6
Show source code of this method: menuItemList Source Code

public static string
(mixed &$row, mixed $id)

Build the select list for Menu Ordering
Parameters
  • object $row The row object
  • int $id The id for the row. Must exist to enable menu ordering
Returns
  • string
Since
  • 1.5
Show source code of this method: ordering Source Code

public static string
(mixed $all = false, mixed $unassigned = false, mixed $clientId = 0)

Build the multiple select list for Menu Links/Pages
Parameters
  • bool $all True if all can be selected
  • bool $unassigned True if unassigned can be selected
  • int $clientId The client id
Returns
  • string
Since
  • 1.5
Show source code of this method: linkOptions Source Code

public static array
(mixed $id, mixed $indent, mixed $list, mixed &$children, mixed $maxlevel = 9999, mixed $level = 0, mixed $type = 1)

Build the list representing the menu tree
Parameters
  • int $id Id of the menu item
  • string $indent The indentation string
  • array $list The list to process
  • array $children The children of the current item
  • int $maxlevel The maximum number of levels in the tree
  • int $level The starting level
  • int $type Set the type of spacer to use. Use 1 for |_ or 0 for -
Returns
  • array
Since
  • 1.5
Show source code of this method: treerecurse Source Code

Properties Summary

protected static array
$menus
Cached array of the menus.
Since
  • 1.6
protected static array
$items
Cached array of the menus items.
Since
  • 1.6

Tags Summary

Since
1.5