function imageapi_optimize_pipeline_delete_form in Image Optimize (or ImageAPI Optimize) 7.2
Form builder; Form for deleting an image pipeline.
Parameters
$pipeline: An image pipeline array.
See also
image_pipeline_delete_form_submit()
1 string reference to 'imageapi_optimize_pipeline_delete_form'
- imageapi_optimize_menu in ./
imageapi_optimize.module - Implements hook_menu().
File
- ./
imageapi_optimize.admin.inc, line 324
Code
function imageapi_optimize_pipeline_delete_form($form, &$form_state, $pipeline) {
$form_state['pipeline'] = $pipeline;
$replacement_pipeline = array_diff_key(imageapi_optimize_pipeline_options(TRUE, PASS_THROUGH), array(
$pipeline['name'] => '',
));
$form['replacement'] = array(
'#title' => t('Replacement pipeline'),
'#type' => 'select',
'#options' => $replacement_pipeline,
'#empty_option' => t('No replacement, just delete'),
);
return confirm_form($form, t('Optionally select a pipeline before deleting %pipeline', array(
'%pipeline' => $pipeline['label'],
)), 'admin/config/media/imageapi-optimize', t('If this pipeline is in use on the site, you may select another pipeline to replace it.'), t('Delete'), t('Cancel'));
}