LimeSurvey API - Master branch

ButtonWidget extends CInputWidget
in package

Creates a button based on given options to fit the admin theme design.

Table of Contents

Properties

$displayDropDownIcon  : bool
$dropDownContent  : string
$dropDownIcon  : string
$htmlOptions  : array<string|int, mixed>
$icon  : string
$iconPosition  : string
$isDropDown  : bool
$link  : string
$text  : string

Methods

init()  : mixed
Initializes the widget
registerClientScript()  : mixed
Registers required script files
renderButton()  : mixed
Renders the button
run()  : mixed
Executes the widget
setDefaultOptions()  : mixed
Analyzes given parameters and htmlOptions and sets default values when options are not given

Properties

$displayDropDownIcon

public bool $displayDropDownIcon

if the 'divider plus another icon' is displayed. true or false (true, if not set and 'isDropDown' is true)

$dropDownContent

public string $dropDownContent = ''

string that should contain valid html list for bootstrap dropdown button. Only used when not empty and isDropDown is true

$dropDownIcon

public string $dropDownIcon = 'ri-more-fill'

the icon displayed besides the divider, default is

$htmlOptions

public array<string|int, mixed> $htmlOptions = []

html options

$icon

public string $icon = ''

name of the icon class. e.g.: ri-brush-fill

$iconPosition

public string $iconPosition = 'left'

Position of the icon either left or right

$isDropDown

public bool $isDropDown = \false

if button should behave as dropdown true or false

public string $link = ''

link where the button points to, if link is empty an

Methods

registerClientScript()

Registers required script files

public registerClientScript() : mixed

renderButton()

Renders the button

public renderButton() : mixed

setDefaultOptions()

Analyzes given parameters and htmlOptions and sets default values when options are not given

private setDefaultOptions() : mixed

        
On this page

Search results