Phpxforms documentation

PluginGroups extends Plugin
in package

Functional extension for

Table of Contents

Properties

$backward  : bool
$dataMiddle  : array<string|int, array<string|int, string|int>>|null
$groups  : array<string|int, array<string|int, string|int>|string|int>
$inpFrom  : Input}|Input|string
$inpTo  : Input}|Input|string
$mark  : string
$mode  : string
$preload  : bool
$url  : string|null

Methods

__construct()  : mixed
getCss()  : array<string, mixed>|null
Get css for plugin
getForm()  : string
Get html code for current (sub)form
getGroups()  : array<string|int, array<string|int, string|int>|string|int>
getScriptDummy()  : string|null
Get javascript for current (sub)form
getScriptForm()  : array<string, mixed>|null
Get javascript for current (multi)form
getScriptTable()  : array<string, mixed>|null
isValid()  : bool
Check plugins validity based on selected form
setGroups()  : void
Set connection between inputs can be defined as $data = [key=>[allowed_keys]] or $data = [key=>group_name] and $middle = [group_name=>[allowed_keys]]
checkInput()  : bool
getInput()  : Input
getInputMark()  : string
getScriptInput()  : string
isValidInput()  : bool

Properties

$backward

protected bool $backward = true

Is possible to choose from target without source option

$dataMiddle

protected array<string|int, array<string|int, string|int>>|null $dataMiddle = null

$groups

protected array<string|int, array<string|int, string|int>|string|int> $groups = []

$mode

protected string $mode = 'disable'

Disable or hide items

$preload

protected bool $preload = false

Load all data if url is set

$url

protected string|null $url = null

Download group definitions

Methods

__construct()

public __construct(Input}|Input|string $inpFrom, Input}|Input|string $inpTo[, array<string, mixed> $options = [] ]) : mixed
Parameters
$inpFrom : Input}|Input|string
$inpTo : Input}|Input|string
$options : array<string, mixed> = []

getCss()

Get css for plugin

public getCss() : array<string, mixed>|null
Return values
array<string, mixed>|null

getForm()

Get html code for current (sub)form

public getForm(string|int $id[, bool $dummy = false ]) : string
Parameters
$id : string|int
$dummy : bool = false
Return values
string

getGroups()

public getGroups() : array<string|int, array<string|int, string|int>|string|int>
Return values
array<string|int, array<string|int, string|int>|string|int>

getScriptDummy()

Get javascript for current (sub)form

public getScriptDummy(string $jsForm) : string|null
Parameters
$jsForm : string
Return values
string|null

getScriptForm()

Get javascript for current (multi)form

public getScriptForm(string $jsForm) : array<string, mixed>|null
Parameters
$jsForm : string
Return values
array<string, mixed>|null

getScriptTable()

public getScriptTable(int $id, string $form) : array<string, mixed>|null
Parameters
$id : int
$form : string
Tags
todo

Get javascript for control table

Return values
array<string, mixed>|null

isValid()

Check plugins validity based on selected form

public isValid(Form $form) : bool
Parameters
$form : Form
Return values
bool

setGroups()

Set connection between inputs can be defined as $data = [key=>[allowed_keys]] or $data = [key=>group_name] and $middle = [group_name=>[allowed_keys]]

public setGroups(array<string|int, array<string|int, string|int>|string|int> $data[, array<string|int, array<string|int, string|int>>|null $middle = null ]) : void
Parameters
$data : array<string|int, array<string|int, string|int>|string|int>
$middle : array<string|int, array<string|int, string|int>>|null = null

checkInput()

protected checkInput(mixed $inp) : bool
Parameters
$inp : mixed
Tags
throws
InvalidArgumentException
Return values
bool

getInputMark()

protected getInputMark(Input|string $inp) : string
Parameters
$inp : Input|string
Return values
string

getScriptInput()

protected getScriptInput(Input}|Input|string $inp) : string
Parameters
$inp : Input}|Input|string
Tags
throws
InvalidArgumentException
Return values
string

isValidInput()

protected isValidInput(string|input $value, array<string|int, string|int>|string|int $allowed) : bool
Parameters
$value : string|input
$allowed : array<string|int, string|int>|string|int
Return values
bool

        
On this page

Search results