Grouping property
Allows organizing block properties into logical groups.
A complex blocks, such as registration form, frequently has a lot of properties.
Finding a necessary property in a big list may not be so easy.
You may help user updating block properties by organizing them into logical groups - form labels, error messages, and so on.
The grouping property has three additional parameters: check, show, and color.
check
Optional. Adds checkbox to a group. Parameter value defines checkbox state.
Property value is equal to 1 when checkbox is ticked. Otherwise, it is zero.
show
Optional. Specifies whether group is expanded or collapsed. The parameter may have the following values:
| Value |
Description |
| 0 |
Group collpased. |
| 1 |
Group exapnded. |
|
color
Optional. Specifies group border color.
Example
<? $info = 'Subscribe form'; $properties = Array( 'group01' => Array( 'type' => '-', 'label' => 'Form labels', 'check' => 1, 'value' => 0, 'show' => 1, 'color' => '#FF0000' ), 'email' => Array( 'type' => 'string', 'label' => 'Your email', 'value' => 'Your email address' ), 'submit' => Array( 'type' => 'string', 'label' => 'Submit button', 'value' => 'Subscribe' ), 'group02' => Array( 'type' => '-', 'label' => 'Error messages', 'value' => 1, 'check' => 1 ), 'emailIsEmpty' => Array( 'type' => 'string', 'label' => 'Email is empty', 'value' => 'Please enter your email address.' ), 'group02close' => Array( 'type' => '/-' ), 'thanksText' => Array( 'type' => 'html', 'label' => 'Thank you', 'value' => 'Thank you for subscribing!' ), 'sendNotificationTo' => Array( 'type' => 'string', 'label' => 'Notify', 'value' => 'admin@company.com' ) ); ?>
|
| Please login to add comments. |
|
|