Toolbar
ToolBar handler
| since |
1.5 |
|---|---|
| package |
Joomla CMS |
Methods
__construct
Constructor
__construct(string name = 'toolbar') : mixed
| since |
1.5 |
|---|
Arguments
- name
stringThe toolbar name.
Response
mixed
addButtonPath
Add a directory where Toolbar should search for button types in LIFO order.
addButtonPath(mixed path) : void
You may either pass a string or an array of directories.
Toolbar will be searching for an element type in the same order you added them. If the parameter type cannot be found in the custom folders, it will look in libraries/joomla/html/toolbar/button.
| since |
1.5 |
|---|
Arguments
- path
mixedDirectory or directories to search.
appendButton
Set a value
appendButton() : string
| since |
1.5 |
|---|
Response
stringThe set value.
getInstance
Returns the global Toolbar object, only creating it if it doesn't already exist.
getInstance(string name = 'toolbar') : \JToolbar
| since |
1.5 |
|---|
Arguments
- name
stringThe name of the toolbar.
Response
\JToolbarThe JToolbar object.
getItems
Get the list of toolbar links.
getItems() : array
| since |
1.6 |
|---|
Response
array
getName
Get the name of the toolbar.
getName() : string
| since |
1.6 |
|---|
Response
string
loadButtonClass
Load the button class including the deprecated ones.
loadButtonClass(string type) : string|null
| since |
3.8.0 |
|---|
Arguments
- type
stringButton Type
Response
string|null
loadButtonType
Loads a button type.
loadButtonType(string type, bool new = false) : bool
| since |
1.5 |
|---|
Arguments
- type
stringButton Type- new
boolFalse by default
Response
bool
prependButton
Get a value.
prependButton() : string
| since |
1.5 |
|---|
Response
string
render
Render a toolbar.
render() : string
| since |
1.5 |
|---|
Response
stringHTML for the toolbar.
renderButton
Render a button.
renderButton(object &node) : string
| since |
1.5 |
|---|
Arguments
- node
objectA toolbar node.
Response
string
Properties
_name
Toolbar name
Type(s)
string
_bar
Toolbar array
Type(s)
array
_buttons
Loaded buttons
Type(s)
array
_buttonPath
Directories, where button types can be stored.
Type(s)
array
instances
Stores the singleton instances of various toolbar.
| since |
2.5 |
|---|
Type(s)
\Joomla\CMS\Toolbar\Toolbar