Actions

J1.5

Difference between revisions of "How to create a custom button"

From Joomla! Documentation

(Customizing the back end toolbar, building custom buttons.)
 
Line 1: Line 1:
The scripts below are used for using the backend toolbar when developing components or modules.
+
The scripts below are used for using the back end toolbar when developing components or modules.
  
Put this script on your component for a custom button:
+
Put this script on your component or module code to make a custom button:
  
JToolBarHelper::custom($task = '',
+
'''JToolBarHelper::custom("task",
$icon = '',
+
"icon",
$iconOver = '',
+
"icon over",
$alt = '',
+
"alt",
$listSelect = true,
+
boolean,
$x = false);
+
boolean);'''
  
 
For a back button you can use this one:
 
For a back button you can use this one:
  
JToolBarHelper::back();
+
'''JToolBarHelper::back();'''
  
 
Calcel button:
 
Calcel button:
 
+
'''
JToolBarHelper::cancel();
+
JToolBarHelper::cancel();'''
  
 
Apply button:
 
Apply button:
  
JToolBarHelper::apply();
+
'''JToolBarHelper::apply();'''

Revision as of 07:47, 31 May 2008

Replacement filing cabinet.png
This Namespace has been archived - Please Do Not Edit or Create Pages in this namespace. Pages contain information for a Joomla! version which is no longer supported. It exists only as a historical reference, will not be improved and its content may be incomplete.

The scripts below are used for using the back end toolbar when developing components or modules.

Put this script on your component or module code to make a custom button:

JToolBarHelper::custom("task", "icon", "icon over", "alt", boolean, boolean);

For a back button you can use this one:

JToolBarHelper::back();

Calcel button: JToolBarHelper::cancel();

Apply button:

JToolBarHelper::apply();