class ConfirmButton extends ToolbarButton

Renders a standard button with a confirm dialog

Methods

__construct( object $parent = null)

Constructor

string
getName()

Get the element name

string
render( array $definition)

Get the HTML to render the button

string
fetchIconClass( string $identifier)

Method to get the CSS class name for an icon identifier

string
fetchButton( string $type = 'Confirm', string $msg = '', string $name = '', string $text = '', string $task = '', boolean $list = true, boolean $hideMenu = false)

Fetch the HTML for the button

string
fetchId( string $type = 'Confirm', string $msg = '', string $name = '', string $text = '', string $task = '', boolean $list = true, boolean $hideMenu = false)

Get the button CSS Id

Details

__construct( object $parent = null)

Constructor

Parameters

object $parent The parent

string getName()

Get the element name

Return Value

string type of the parameter

string render( array $definition)

Get the HTML to render the button

Parameters

array $definition &$definition Parameters to be passed

Return Value

string

string fetchIconClass( string $identifier)

Method to get the CSS class name for an icon identifier

Can be redefined in the final class

Parameters

string $identifier Icon identification string

Return Value

string CSS class name

string fetchButton( string $type = 'Confirm', string $msg = '', string $name = '', string $text = '', string $task = '', boolean $list = true, boolean $hideMenu = false)

Fetch the HTML for the button

Parameters

string $type Unused string.
string $msg Message to render
string $name Name to be used as apart of the id
string $text Button text
string $task The task associated with the button
boolean $list True to allow use of lists
boolean $hideMenu True to hide the menu on click

Return Value

string

string fetchId( string $type = 'Confirm', string $msg = '', string $name = '', string $text = '', string $task = '', boolean $list = true, boolean $hideMenu = false)

Get the button CSS Id

Parameters

string $type Button type
string $msg Message to display
string $name Name to be used as apart of the id
string $text Button text
string $task The task associated with the button
boolean $list True to allow use of lists
boolean $hideMenu True to hide the menu on click

Return Value

string Button CSS Id