function coloractions_adjustlevels_form_helper in ImageCache Actions 8
Same name and namespace in other branches
- 7 coloractions/imagecache_coloractions.module \coloractions_adjustlevels_form_helper()
Helper function to create the form for the color level adjustment effect.
Parameters
array $data: Array containing the form elements names as keys for array elements containing title and default value.
Return value
array
1 call to coloractions_adjustlevels_form_helper()
- coloractions_adjustlevels_form in coloractions/
imagecache_coloractions.module - Image effect form callback for the brightness effect.
File
- coloractions/
imagecache_coloractions.module, line 924
Code
function coloractions_adjustlevels_form_helper(array $data) {
$form = array();
foreach ($data as $name => $value) {
$form[$name] = array(
'#type' => 'textfield',
'#title' => $value['title'],
'#default_value' => $value['default'],
'#size' => 5,
'#element_validate' => array(
'coloractions_validate_scale_0_1',
),
);
}
return $form;
}