You are here

function heartbeat_comments_multiple_delete_confirm_submit in Heartbeat 6.4

Same name and namespace in other branches
  1. 7 modules/heartbeat_comments/heartbeat_comments.admin.inc \heartbeat_comments_multiple_delete_confirm_submit()

Process comment_multiple_delete_confirm form submissions.

Perform the actual comment deletion.

File

modules/heartbeat_comments/heartbeat_comments.admin.inc, line 193
Admin page callbacks for the heartbeat comments module.

Code

function heartbeat_comments_multiple_delete_confirm_submit($form, &$form_state) {
  if ($form_state['values']['confirm']) {
    foreach ($form_state['values']['comments'] as $cid => $value) {
      _heartbeat_comments_delete($cid);
    }
    drupal_set_message(t('The comments have been deleted.'));
  }
  $form_state['redirect'] = 'admin/content/heartbeat/comments';
}