You are here

function imagepicker_multitask_delete_form_submit in Image Picker 6.2

Same name and namespace in other branches
  1. 7 imagepicker.functions.inc \imagepicker_multitask_delete_form_submit()

Submit form

1 string reference to 'imagepicker_multitask_delete_form_submit'
imagepicker_multitask_delete_form in ./imagepicker.functions.inc

File

./imagepicker.functions.inc, line 658
Imagepicker functions

Code

function imagepicker_multitask_delete_form_submit($form, &$form_state) {
  $simg_ids = $form_state['values']['simg_ids'];
  $returnpath = $form_state['values']['returnpath'];
  $img_ids = explode('-', $simg_ids);
  foreach ($img_ids as $img_id) {
    _imagepicker_image_delete($img_id, FALSE, 'admin', TRUE);
  }
  drupal_set_message(t('%c deleted', array(
    '%c' => format_plural(count($img_ids), '1 image', '@count images'),
  )));
  $rpath = imagepicker_multitask_returnpath($returnpath);
  drupal_goto($rpath);
}